cookie-question

Results 1 to 2 of 2

Thread: cookie-question

  1. #1
    Karel Guest

    Default cookie-question

    Hi,<BR><BR>I want a database-linked text being displayed on my homepage. But when a user visits the homepage for the 2,3,... time, I want to display a different(next, not random) text being displayed on the homepage. I know it has something to do with cookies, but I don&#039t know exactly how it works. Can someone help me out?<BR><BR>Thanks a lot<BR>Karel

  2. #2
    brad brunfelt Guest

    Default RE: cookie-question

    go to http://www.powerasp.com/content/code-snippets/cookies.asp<BR>to get the basics on cookies. <BR><BR>After that you&#039ll probably set a value like <BR>Response.Cookies ("MYCOOKIE")("TimesVisited") = 1<BR><BR>when the user visits again you check if the TimesVisited value of the TimesVisited =1<BR><BR>If Response.Cookies ("MYCOOKIE")("TimesVisited") &#062;= 1<BR>&#039use a differennt field from database to display text<BR>&#039and add 1 to the value of the TimesVisted value so it will <BR>&#039change next time as well <BR>Else response.cookie = 1<BR><BR>thats my 2 cents <BR>

Posting Permissions

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