Re: Pass variables with PHP_SELF?

From: Date: Sun, 15 Jul 2001 19:06:47 +0000
Subject: Re: Pass variables with PHP_SELF?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-57976@lists.php.net to get a copy of this message
Hi David, If you know that the first form has been submitted, you could pass the variables through hidden variables: <? if (isset($whatever)) { echo "<input type=\"hidden\" name=\"whatever\" value=\"" . $whatever . "\">"; } ?> Should work...... And it's often better going through the POST method rather than the GET method (particularly if you want to restrict the user from tampering with the variables). James "David" <yngwie@home.com> wrote in message news:3B51C8AE.C37EB0D8@home.com... > How do you pass a variable that was passed from one form to another form > and then to PHP_SELF? The first part works fine: I passed a variable > from one form to another page with a form using > blah.php?id=$id&songsinalbum=$songsinalbum but when someone submits > the second form the value of $songsinalbum is not passed when using > PHP_SELF. Do I have to pass to another page? I want to use PHP_SELF > > >

« previous php.general (#57976) next »