session vars with recursive form
| From: | bill | Date: | Fri, 12 Jan 2001 19:24:52 +0000 |
| Subject: | session vars with recursive form | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-34285@lists.php.net to get a copy of this message | ||
How can I correctly register session vars on a recursive form?
If I call a page repeatedly using:
<FORM ACTION="<?php echo $PHP_SELF ?>" METHOD="POST">
The earlier variables keep getting lost.
How can I register the session variables correctly? Each subsequent
page should set its own variable while remembering all those previously
set.
Right now the top of the page says:
-----------
session_start();
$thevals=array(alpha,beta,gamma,delta,epsilon);
while (list($key, $val) = each($thevals)) {
if (!session_is_registered($val) ) {
session_register("$val");
}
}
----------
thanks,
bill