PHP dynamic page, how to use session instead of passd parms?

A

Anonymous

Guest
I have a website that uses DW,PHP, & Mysql to display some dynamic information.

Currently the search page has two fields on it. One is State and the other is Month. This information is then passed via URL parameters to the results page.

How can I use sessions to pass these parameters instead?

I don't want these parameters displayed on the URL.

Thanks for any info
 
You're thinking in slightly the wrong direction, here. You don't need sessions. Instead, you need to set your form method to POST instead of GET, e.g.:

Code:
<form action="script.php" method="POST">
   ...
</form>

Then to retrieve the passed values, use the array $POST (or $HTTP_POST_VARS) instead of $GET ($HTTP_GET_VARS).
 
Back
Top