This commit is contained in:
Gnieark 2016-06-09 19:22:29 +02:00
parent df730d3056
commit 0970f6b740
2 changed files with 4 additions and 7 deletions

View File

@ -97,7 +97,7 @@ switch($_POST['act']){
error(404,"wrong post parameter");
die;
}
echo "plop";
$err="";
//check author e-mail
@ -122,7 +122,7 @@ switch($_POST['act']){
}
//BotUrl
if(($_POST['botURL'] <> "") && (!preg_match("/^(http|https):\/\//", $_POST['botURL']))){
$alerts.="L'URL n'est pas valide.\n";
$err.="L'URL n'est pas valide.\n";
}
if($err == ""){
@ -186,11 +186,7 @@ switch($_POST['act']){
}else{
//echo "plop".$err."plop"; die;
}
break;
default:

View File

@ -11,7 +11,7 @@ if(isset($_POST['xd_check'])){
if((isset($err)) && ($err <> "")){
$message="<h3>".$err."</h3>";
$editDone=false;
}elseif($err == ""){
}else{
$editDone=true;
}
@ -33,6 +33,7 @@ if($editDone){
}else{
?>
<h2>EditBot</h2>
<?php echo $message; ?>
<form method="POST" action="/p/editBot/<?php echo $theBot['id']; ?>">
<?php echo xd_check_input(0); ?><input type="hidden" name="act" value="editBot"/><input type="hidden" name="botId" value="<?php echo $theBot['id']; ?>"/>
<p><label for="botName"><?php echo $lang['BOT_NAME']; ?></label><input id="botName" type="text" name="botName" value="<?php echo htmlentities($botName); ?>" placeholder="<?php echo $lang['YOUR_ALIAS_FOR_EXEMPLE'];?>"/></p>