This is a discussion on session and back within the PHP Language forums, part of the PHP Programming Forums category; I'm planning to modify my site from "POST" to "SESSION"....This is because many times, ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
I'm planning to modify my site from "POST" to "SESSION"....This is because
many times, when clicking "back" on the browser, the page has to be refreshed, and I absolutely want to avoid this, also I don't want to use "GET" variables, as they are visible in the URL and I want to avoid this (POST are also visible but not for everyone. session would be hidden) If I use Session variables, will this fix the problem with "back" button ? or may I have the same problem ? Thanks for help. Cheers. Bob |
|
|||
|
"Bob Bedford" <bedford1@YouKnowWhatToDoHerehotmail.com> wrote in
news:4176cc48$0$28012$5402220f@news.sunrise.ch: > If I use Session variables, will this fix the problem with "back" > button ? or may I have the same problem ? page 1 could check for the existance of session variables, which wont be there the first time around, so they will be blank. post to the second page normally. put the post variables into sessions, named as you want them. when going back to the first page, it will check for the existance of sessions again, and they will be there. Ive never used sessions directly in a form. actually I didnt know it could be done. |
|
|||
|
"Theo" <invalid@noemail.com> wrote in message news:Xns95889425266FEdensnews123@216.168.3.44... > "Bob Bedford" <bedford1@YouKnowWhatToDoHerehotmail.com> wrote in > news:4176cc48$0$28012$5402220f@news.sunrise.ch: > >> If I use Session variables, will this fix the problem with "back" >> button ? or may I have the same problem ? > > page 1 could check for the existance of session variables, which wont be > there the first time around, so they will be blank. post to the second > page > normally. put the post variables into sessions, named as you want them. > when going back to the first page, it will check for the existance of > sessions again, and they will be there. > > Ive never used sessions directly in a form. actually I didnt know it could > be done. You cannot use sessions in a form, but you can use session data to create a form. Session data exists on the server only, and what is sent to the client browser is an HTML document which may contain values obtained from the session data. If you are having problems with the BACK button ten read http://www.tonymarston.co.uk/php-mys...ttonblues.html -- Tony Marston http://www.tonymarston.net |
|
|||
|
"Tony Marston" <tony@NOSPAM.demon.co.uk> wrote in
news:cl7i2d$8k5$1$8302bc10@news.demon.co.uk: > You cannot use sessions in a form, but you can use session data to > create a form. Session data exists on the server only, and what is > sent to the client browser is an HTML document which may contain > values obtained from the session data. > thats what I thought, but there have been enough undocumented things to make me go 'hmmmmm'. |