Nous les mini-patchs, nanananananana !

This commit is contained in:
Alan Garcia 2013-01-31 17:00:39 +00:00
parent 4519fccd25
commit f15b47b43a
3 changed files with 5 additions and 4 deletions

View File

@ -79,11 +79,12 @@ include_once("head.php");
$content=$bro->content($R,$editfile);
if (empty($content)) {
$failed=true;
$error=_("This file is empty");
} else {
echo $content;
}
?></textarea>
<?php if ($failed) echo "<p class=\"error\">".$err->errstr()."</p>"; ?>
<?php if (!empty($error)) echo "<p class=\"error\">".$error."</p>"; ?>
<input type="hidden" name="editfile" value="<?php echo str_replace("\"","&quot;",$editfile); ?>" />
<input type="hidden" name="R" value="<?php echo str_replace("\"","&quot;",$R); ?>" />

View File

@ -45,9 +45,9 @@ include_once("head.php");
}
?>
<form method="post" action="hta_doadd.php" name="main" id="main">
<table border="1" cellspacing="0" cellpadding="4">
<table border="1" cellspacing="0" cellpadding="4" class='tedit'>
<tr>
<td><label for="dir"><?php __("Folder"); ?></label></td>
<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" />
<?php display_browser( ehe($dir,0) , "main.dir" ); ?>
</td>

View File

@ -244,7 +244,7 @@ class m_hta {
}
}
fseek($file,SEEK_END);
if (substr($t[1],-1)!="\n") {
if ( empty($t[1]) || substr($t[1],-1)!="\n") {
fwrite($file,"\n");
}
fwrite($file, "$user:"._md5cr($password)."\n");