I have a question about cookies. I have written a function, see below, that writes a cookie based on the parameters passed to it when it is called. I have this stored in a included file called cookiestuff.asp that I use when I need to perform cookie functions. I also have a function that validates the cookie. To validate I do this. if isValid(30) then etc... The problem I am having is when I set my from cookie variable. It seems a though it gets the new value that I set it to. So it is always valid. Anyone got any advice for me?<BR><BR>function isValid(sessTimeOut)<BR> if Request.Cookies("cookiename") = "" then<BR> tempVar = false<BR> else<BR> fromCookie = Request.Cookies("cookiename")("lastaccessed")<BR> timeDiff = datediff("n",lastaccessed,now())<BR> if isSessionOk(timeDiff,sessTimeOut) then<BR> tempVar = true<BR> Response.Cookies("cookiename")("lastaccessed")= now()<BR> Response.Cookies("cookiename").Domain = "domainname"<BR> Response.Cookies("cookiename").Expires = Date() + 1<BR> else<BR> tempVar = false<BR> end if<BR> end if<BR> isValid=tempVar<BR> set tempVar=nothing<BR> end function<BR><BR>function isSessionOk(currMin,timeOut)<BR> dim sVar1<BR> if currMin &#062; timeOut then<BR> sVar1 = False<BR> else<BR> sVar1 = True<BR> end if<BR> isSessionOk = sVar1<BR> set sVar1 = nothing<BR> end function<BR><BR>function SetCookie(cookieName,cookieKey,cookieDomain,cookie Expires,cookieInfo)<BR> Response.Cookies(cookieName)(cookieKey) = cookieInfo<BR> Response.Cookies(cookieName).Domain = cookieDomain<BR> Response.Cookies(cookieName).Expires = cookieExpires<BR> end function