Re: Passing vars
| From: | Maureen | Date: | Wed, 14 Feb 2001 20:51:07 +0000 |
| Subject: | Re: Passing vars | ||
| References: | 1 | Groups: | php.db php.general |
| Request: | Send a blank email to php-general+get-39739@lists.php.net to get a copy of this message | ||
I may be totally wrong or missing something, (if so, someone please let me know) but ...
1. One way would be to use the variables and urlencode them before passing them.
$var1=urlencode($var1)
then you have test.php?cheese="<?echo $var1?>"
OR
2. Another way would be to use a form:
<form method=post action="test.php">
and then add the 6 variables as
<input type=hidden name="var1" value="<?echo $var1?>">
<input type=hidden name="var2" value="<?echo $var2?>">
<input type=hidden name="var3" value="<?echo $var3?>">
<input type=hidden name="var4" value="<?echo $var4?>">
<input type=hidden name="var5" value="<?echo $var5?>">
<input type=hidden name="var6" value="<?echo $var6?>">
and then have a submit button to take you to the next page.
Tanya Brethour wrote:
Quick question.. If I have like 6 variables to pass to another PHP script... and some of the vars are actually multiple lines of text (lets say over 30 lines). What is the best way of doing this? I would like to avoid doing something like test.php?cheese=(30 lines of stuff) Thanks in advance! -Tanya