Problems with a web-based database

Results 1 to 2 of 2

Thread: Problems with a web-based database

  1. #1
    Steve Greenwood Guest

    Default Problems with a web-based database

    Hi,<BR><BR>I&#039m having some problems with my database.<BR><BR>I&#039m using Personal Web Server for Windows 98 and an Access 97 database.<BR><BR>Firstly, I need to pass varibles between ASP pages without using forms. Basically, the idea is that the user searchs by a region, and receives a list of towns. He then clicks on a town to search by that town. The ASP code gets the town names and outputs them to the page OK, but I then need to transfer the town name to the next ASP page. I&#039ve tried using the Request code as part of the URL, but that does not replace the code with the town name.<BR><BR>Secondly, when I attempt to run a query a second time, Personal Web Server crashes. I then need to reboot.<BR><BR>Any help would be great.<BR><BR>Steve Greenwood<BR>

  2. #2
    Join Date
    Dec 1969

    Default Use Querystring....

    You could do it like this. Suppose that you have the page SearchByTown.asp in mind. When you output the list of towns, append a variable in the querystring:<BR><BR>&#060;A HREF="SearchByTown.asp?townID=&#060;%=rs("ID")%&#0 62;"&#062;Chicago&#060;/A&#062;<BR><BR>Here, I have assumed that you have a rs open, and can access the town&#039s ID via rs("ID")....modify as necessary....then, on the SearchByTown.asp receiving page, you call the Request.QueryString object to get the town&#039s ID:<BR><BR>theTownID = Request.QueryString("townID")<BR><BR>You can then use that ID in whatever fashion you wish....<BR><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