deadlock Message Board
[ June Full List | Reply ]

Re: Help Please
From David A on 15 June '00
replying to Help Please posted by Thomas

>I am actually having a nightmare trying to do this so I thought I would post this to see if anyone out their can help.
>I am trying to create a "Your Path" on my site so that users can view where they have been and for ease of navigation.
>An example would be
>Your Path: Home : categories : amino acids
>The problem I am running into is that my site is using ASP w/ VB script. My products are all stored in a database and I dont know how to call the product or the category that the product is in (especially making it a link). Any code or insight would be extremley appreciated.

Not sure if I understand the question but I'll try an answer anyway.
I'm coming from a PHP background on this but the principles are probably the same.

First create a column in the database which contains the category which that product is in. That way you can search and index according to the category.

As far as linking. Have an IF/ELSE loop which sends a query to the database based on the variables passed to the page.

OK that wasn't very clear.

lets assume your page is called products.asp.
On that page you have code like: (not actual code)

IF category=1 then database query = return everything with cateory 1.

ELSEIF category=2 then database query = return everything with cateory 2.

Calling this url 'products.asp?category=1' would result in product 1 categories being displayed. 'products.asp?category=2 would show category 2 items.

Basically the results returned by the database is determined by an IF loop which is passed variables via the URL. Hopefully that remotely makes sense.

Reply to this message

Required Details
Your name:

Optional Details
Home page title:
Home page URL:
(if you'd like to receive automatic replies by email)

Your Message