Raggaer
Godly Member
Hi, I have a big problem
Using this , this code executes
But I need that when u click submit you get to new page so I use this
but then the code doestn execute ;S dont know why
Thanks
PHP:
<form action="index.php" method="post">
PHP:
if ($_POST['submit']) {
$rules = $_POST['rules'];
$title = $_POST['title'];
$body = $_POST['body'];
$date = date("Y-m-d");
if ($title && $body) {
if ($rules == 'on') {
$filename = 'w'.$title.'.txt';
$handle = fopen('pastes/'.$filename, 'w');
fwrite($handle, $body);
fclose($handle);
$query = mysql_query("INSERT INTO codes VALUES ('','$title','$body','$date')");
} else {
echo '<b>Accept our rules</b>';
}
} else {
echo '<b>Fill all fields</b>';
}
}
But I need that when u click submit you get to new page so I use this
PHP:
<form action="see.php" method="post">
but then the code doestn execute ;S dont know why
Thanks
Last edited: