Help on Cookies

Results 1 to 3 of 3

Thread: Help on Cookies

  1. #1
    Sean K. Guest

    Default Help on Cookies

    I am trying to get this to work so I know it&#039;s working. That didn&#039;t make sense but anyways here goes, I&#039;m just writing a cookie and in this I am including a conditional if a cookie already exists on the browser i don&#039;t want to overwrite it, so I have the following code to tell me if it&#039;s a new cookie or an old one and it&#039;s supposed to display the information(a GUID) in the cookie but that&#039;s where I&#039;m stuck:<BR>--------------------------------------------------------------<BR>Set MyGuid = Server.CreateObject ("GuidMakr.GUID")<BR> sGUID = MyGuid.GetGUID<BR> Dim sCookieValue<BR> sCookieValue = Request.Cookies("Prototype")<BR> If IsNull(sCookieValue) Then<BR> Response.Cookies("Prototype")("GUID") = sGUID<BR> Response.Cookies("Prototype").Expires = dateadd("d",5,now)<BR> Response.Write "NEW GUID #: "<BR> Response.Write Request.Cookies("Prototype")("GUID") & "break"<BR> Else<BR> Response.Write "OLD GUID #: " & Request.Cookies("Prototype")("GUID") & "break"<BR> End If<BR>--------------------------------------------------

  2. #2
    Join Date
    Dec 1969

    Default RE: Help on Cookies

    If len(sCookieValue & "") = 0 Then

  3. #3
    Sean K. Guest

    Default That worked! A thousand thank-yous <end>


Posting Permissions

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