1. You are viewing our forum as a guest. For full access please Register. WindowsBBS.com is completely free, paid for by advertisers and donations.

Help With Database Functionality on Web Site

Discussion in 'Other PC Software' started by Mr. Chip, 2006/07/22.

  1. 2006/07/22
    Mr. Chip Lifetime Subscription

    Mr. Chip Well-Known Member Thread Starter

    Joined:
    2005/06/30
    Messages:
    427
    Likes Received:
    0
    :confused:

    Hello,

    I am looking for an easy way to implement some new functionality on my website. The website is created in FrontPage 2002 and the server has all the FP extensions installed.

    I have a "database" file that has 5,000 records. Each record has a single datapoint in it. The datapoint is a custom hyperlink that sends people to a secure site. For example, the file may look like this:

    Hyperlink
    site.com/link1.htm
    site.com/link2.htm
    site.com/link3.htm...
    site.com/link5000.htm

    I say this is a "database" file because it could be stored in Access or as an xls, txt, or csv file.

    Here is what I want to happen. When someone visits a particular page on my website, I want the page to display the first hyperlink "site.com/link1.htm" (but only the first one). Ideally, the link will be active so that the user can click on it and be forwarded to the new site. Once that hyperlink has displayed, I want it to be flagged as "used ". Once a link is "used ", it will never be displayed again. The next visitor to that page will see the second hyperlink, and so on.

    An acceptable alternative solution is once a link has been displayed, it can be deleted (as opposed to being flagged as used) from the "database" file.

    I would also like the ability to add hyperlinks to the file after the first 5,000 are used.

    Does anyone know how I can implement this? Please provide as much detail as possible.

    Thanks!
     
  2. 2006/07/23
    TonyT

    TonyT SuperGeek Staff

    Joined:
    2002/01/18
    Messages:
    9,072
    Likes Received:
    400
    Explaining why you want to do this will help in determining just how it can be done.

    Some things needed to accomplish what you want to do are:

    1. server side scripting support like php or asp or jsp.
    2. set cookie for each visitor
    3. a database like mysql

    You need a script that checks if a cookie exists & if not then sets a cookie w/ a timestamp value or grabs the existing timestamp value of the cookie and based on the value queries a database & cycles through the 5000 links and then displays the appropriate link on the page.

    There are javascripts that can rotate a list of links, but this will be quite slow for a file w/ 5000 links!
     

  3. to hide this advert.

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.