cookie is set but doesn´t seem to exist...

Results 1 to 2 of 2

Thread: cookie is set but doesn´t seem to exist...

  1. #1
    Robob Guest

    Default cookie is set but doesn´t seem to exist...

    what´s going on when a cookie that I set doesn´t seem to exist on the next page? I set one like this:<BR><BR>Response.Cookies("userinfo")("Passwor d") = SSN<BR>Response.Cookies("userinfo")("SSNP") = Request.Form("SSNP")<BR>Response.Cookies("userinfo ").Secure = True<BR>Response.Cookies("userinfo").Expires = Now() + 1<BR><BR>and then tried to inset certain data from it into a database on the next page in this way:<BR>first I assign it to a local:<BR><BR>Password = Request.Cookies("userinfo")("Password")<BR><BR>and then I try to write that local (Password) into the database.<BR>that´s when the error occured (when trying to write to the database). So what I tried was to make the script write the values of the cookie to the screen so that I could see what they were like this:<BR><BR>Response.Write Request.Cookies("userinfo")("Password")<BR><BR>But all I could see that it didn´t write anything to the screen! I set my security settings up then (prompt before accepting cookies) and it (IE) asks me whether it´s allowed to set a cookie EXACTLY as I want it, with the correct name, and values, expiration date, and everything. I can even read the cookie from my harddrive, and all the values are right! but when it then redirects me to the next page the above mentioned s*** happens!!! what´s going on? (I just tried it with netscape. same thing. I couldn´t find the cookies configuration though)<BR><BR>

  2. #2
    Robob Guest

    Default nevermind - solved it myself - can´t be secure!

    I just figured it out: the cookie I set was set to secure = true. this obviously can´t be read by normal connections ("localhost"). I just read an article on 4guys that explained that "If set, the cookie will only be set if the browser is using secure sockets or https:// to connect." Which was not the case on my computer, of course, so I wonder WHY THIS COOKIE GOT SET INITIALLY without a secure connection. weird.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts