Fix #1549
This commit is contained in:
parent
8fde9a58a2
commit
4108189f4f
|
@ -47,21 +47,24 @@ getFields($fields);
|
|||
echo "<p class=\"alert alert-danger\">$error</p>";
|
||||
include_once("foot.php");
|
||||
exit;
|
||||
}
|
||||
?>
|
||||
} ?>
|
||||
|
||||
<form method="post" action="hta_doadd.php" name="main" id="main">
|
||||
<table border="1" cellspacing="0" cellpadding="4" class='tedit'>
|
||||
<tr>
|
||||
<th><label for="dir"><?php __("Folder"); ?></label></th>
|
||||
<td><input type="text" class="int" name="dir" id="dir" value="<?php (isset($dir)) ? : $dir="";ehe($dir); ?>" maxlength="255" />
|
||||
<td>
|
||||
<input type="text" class="int" name="dir" id="dir" value="<?php (isset($dir)) ? : $dir="";ehe($dir); ?>" maxlength="255" />
|
||||
<?php display_browser( ehe($dir,0) , "main.dir" ); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<br />
|
||||
<input type="submit" class="inb lock" value="<?php __("Protect this folder"); ?>" />
|
||||
<input type="submit" class="inb lock" value="<?php __("Protect this folder"); ?>" onClick="return false_if_empty('dir', '<?php echo addslashes(_("Can't have empty directory."));?>');" />
|
||||
</form>
|
||||
|
||||
<script type="text/javascript">
|
||||
document.forms['main'].dir.focus();
|
||||
</script>
|
||||
|
||||
<?php include_once("foot.php"); ?>
|
||||
|
|
|
@ -35,6 +35,12 @@ $fields = array (
|
|||
);
|
||||
getFields($fields);
|
||||
|
||||
if(empty($dir)) {
|
||||
$error=_("No directory specified");
|
||||
include("hta_list.php");
|
||||
exit();
|
||||
}
|
||||
|
||||
if(!$hta->CreateDir($dir)) {
|
||||
$error=$err->errstr();
|
||||
include("hta_add.php");
|
||||
|
|
Loading…
Reference in New Issue