PHP Question.. clearing variables...
say for example you're submitting a form to the page it is on (php_self).. and say you hit the refresh button after submitting that form... all those variables are re-submitted which causes for duplication... how do you avoid that so that you can clear those variables out?
i thought unset($variable) would work, but it doesn't.
the code looks like:
if (isset($comment)) {
$date = time();
$sqlquery6 = "INSERT INTO bgcomments
VALUES ('id','$_SESSION[username]','$uid','$comment','$date')";
$resultse = mysql_query($sqlquery6);
unset($comment);
}
|