RE: [PHP] Passing _any_ variable to next page
| From: | Christensen, BruceX R | Date: | Wed, 09 Aug 2000 17:04:54 +0000 |
| Subject: | RE: [PHP] Passing _any_ variable to next page | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-10960@lists.php.net to get a copy of this message | ||
Check out WDDX and urlencode() in the manual.
--Bruce
Bruce Christensen
Intel Corporation
brucex.r.christensen@intel.com
-----Original Message-----
From: Jason Brooke [mailto:jason@qgl.org]
Sent: Wednesday, August 09, 2000 8:15 AM
To: stephan.schoell@ch.abb.com; php-general@lists.php.net
Subject: Re: [PHP] Passing _any_ variable to next page
Check the request method - if it's GET, simply append &$QUERY_STRING to your
&lang=x
If it's POST, you might loop over $HTTP_POST_VARS and add hidden fields
containing the key=val pairs if you have a form, or pile them onto the end
of the &lang=x if you have a link
jason
Hi folks,
I think I'm blind, but I'm looking for a way to pass _every_ variable of one
script to another (via URL or form submit, doesn't matter). I'm about to
expand
my site for multilanguage support. So when a visitor e.g. clicks on
"english"
the same page should be called again, with the same variable values as it
has
been called before. I'm lazy, so I don't want to bother which variable is
used/set specifically on a actual page. I just want to dump _any_ variable
to
the next page.
Maybe it works by adding ?HTTP_GET_VARS/?HTTP_PUT_VARS respectively
(track_vars
enabled) to the language choice hrefs. In the next page I have to evaluate
this
array (known procedure).
myscript.php3:
<html>
....
<a href="<?php echo $PHP_SELF."?HTTP_GET_VARS=".$HTTP_GET_VARS
?>&lang=e">click
here for english version</a> |
<a href="<?php echo $PHP_SELF."?HTTP_GET_VARS=".$HTTP_GET_VARS
?>&lang=g">hier
klicken für deutsche Version<a> |
<a href="<?php echo $PHP_SELF."?HTTP_GET_VARS=".$HTTP_GET_VARS
?>&lang=f">cliquer ici pour version françcaise</a>
.....
</html>
Any suggestions, comments or tips? Might it work that way?
Thanx in advance.
--Steff
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
For additional commands, e-mail: php-general-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
For additional commands, e-mail: php-general-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net