...

View Full Version : Simple session redirect



dschnaibe
07-06-2005, 05:11 PM
Hi, I've always been a little slow when it comes to coding. HTML doesn't give me too much of a problem, but some of the more advance features have just plain passed me by. At this point I have basically just confused myself.

First, what I am trying to do is set up, just a simple session cookie to basically skip a flash intro.

I've deduced there are two ways to do this an "OnClick" command to set a cookie or just a standard header cookie on the 2nd page to set it. I've decided that setting the cookie on the non-flash page would be the simplest and least intrusive way to do it.

I've read two ways to do this for example.

document.cookie("flash"=true)
or navigator.cookie(true)

I understand the logic, but do not understand the difference of the two formats.

On the primary page, where the flash is loaded, I planned to put in the header there a if statement, saying something along the lines of

if document.cookie == true(){
window._command I forgot_== ("redirect.htm");

I can't see how this is more than 3 or 4 lines of code. But most java script resources on the web seem to have long ago gone the way of the dodo. I just recently found this place. I looked for a while and found nothing and decided to post here. I am going to continue looking while I wait for an answer. Any explanation to the logic behind the code in novice format would be appreciated too. Or a pointer in the direction of a good tutoring site for total beginners.

Thanks!!

Dan

A1ien51
07-07-2005, 12:24 AM
http://techpatterns.com/downloads/javascript_cookies.php

Eric



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum