Posting variables from one page to another

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
RFairey
Forum Commoner
Posts: 52
Joined: Fri Jun 06, 2003 5:23 pm

Posting variables from one page to another

Post by RFairey »

Can php post variables directly from one page to another? I don't want to use GET as it clutters up the URL, and I don't have any FORM elements to POST. Can you just send some php variables as key/value pairs from one script to the next? Sorry if this topic has been done to death - I'm probably missing something obvious.
[]InTeR[]
Forum Regular
Posts: 416
Joined: Thu Apr 24, 2003 6:51 am
Location: The Netherlands

Post by []InTeR[] »

Have a look at sessions
hedge
Forum Contributor
Posts: 234
Joined: Fri Aug 30, 2002 10:19 am
Location: Calgary, AB, Canada

Post by hedge »

You can do it with socket connections talking http... do a search on this board I have posted code that does exactly that.
RFairey
Forum Commoner
Posts: 52
Joined: Fri Jun 06, 2003 5:23 pm

Post by RFairey »

Ah - all I wanted was an image link that worked like a back button to take you back to the gallery page you had come from (there are more than one).

I found a way of doin it in java script:

Code: Select all

<a href="javascript:history.back()">link</a>
Post Reply