Question about session handling from page to page
Posted: Mon May 19, 2008 4:46 pm
Greetings!
I have a quick question about Session handling and would like some opinions of those who are smarter than me.
Generally, I create all internal site links with a long tail using SID so the user doesn't lose his session (aka, his shopping cart). An example of the code would be:
And the output would be something like this:
Of course this isn't SEO friendly. I have noticed that in the past when I have forgotten to add the SID to the end of the URL, the session still carried over. The cart did not empty.
So, my question is, do I need to do this? Can I take all of the URL SIDs off of my links and still keep sessions from page to page? Does anyone have a more efficient way to do this? I want to clean up the site and make it SEO friendly; I am open to any suggestions. Thanks in advance!
I have a quick question about Session handling and would like some opinions of those who are smarter than me.
Generally, I create all internal site links with a long tail using SID so the user doesn't lose his session (aka, his shopping cart). An example of the code would be:
Code: Select all
print("<a href='faq.php?".SID."'>FAQ</a>Sometimes this shows up in the browser url and sometimes it doesn't.
Of course this isn't SEO friendly. I have noticed that in the past when I have forgotten to add the SID to the end of the URL, the session still carried over. The cart did not empty.
So, my question is, do I need to do this? Can I take all of the URL SIDs off of my links and still keep sessions from page to page? Does anyone have a more efficient way to do this? I want to clean up the site and make it SEO friendly; I am open to any suggestions. Thanks in advance!