session and back

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, ...


Go Back   Usenet Forums > PHP Programming Forums > PHP Language

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 10-20-2004
Bob Bedford
 
Posts: n/a
Default session and back

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


Reply With Quote
  #2 (permalink)  
Old 10-20-2004
Theo
 
Posts: n/a
Default Re: session and back

"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.
Reply With Quote
  #3 (permalink)  
Old 10-21-2004
Tony Marston
 
Posts: n/a
Default Re: session and back


"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



Reply With Quote
  #4 (permalink)  
Old 10-21-2004
Theo
 
Posts: n/a
Default Re: session and back

"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'.
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 08:04 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0