try to hook extraction in the browser

This commit is contained in:
Antoine Beaupré 2008-01-22 03:23:56 +00:00
parent 97d65aadb3
commit 6b07f7f68b
1 changed files with 8 additions and 2 deletions

View File

@ -103,8 +103,13 @@ if ($formu) {
}
break;
case 3: // Upload de fichier...
if (!$bro->UploadFile($R)) {
$target = $bro->UploadFile($R);
if (!$target) {
print $err->errstr();
} elseif ($_POST['extract']) {
if (!$bro->ExtractFile($target)) {
print $err->errstr();
}
}
break;
}
@ -430,7 +435,8 @@ else {
<hr />
<?php __("Import this file"); ?>&nbsp;&nbsp;<input class="int" name="userfile" type="file" />
<input type="hidden" name="MAX_FILE_SIZE" value="10000000" />
<input type="submit" class="inb" value="<?php __("Send"); ?>" />
<input type="submit" class="inb" name="upload" value="<?php __("Send"); ?>" />
<input type="submit" class="inb" name="extract" value="<?php __("Send & Extract"); ?>" />
<hr />
</form>
<p>&nbsp;</p>