I'd say easily enough if you started this project from scratch. Lets say all 
your items fall into certain categories like:

Stereos
Lawn & Garden equipment
Sports equipment
Antiques
Etc.
Etc.

Now lets say you have shortened the names down & added a column within your 
database that holds the value of the categorie that the product falls under. 
The values in that field would look like this:

electronics
antiques
lawn
furniture
etc.
etc.

Ok now lets say you have an images directory that contains a folder for each 
one of those values with the same name. So your images directory contains 
one folder for each categorie value.

Add one more additional field to your database that holds the 
items/inventory image name with the extension. Now the values for that new 
field should look like this:

chair0001.jpg
stereo635.gif
etc.
etc.

In your query for a particular item include the the path (which would be the 
categorie name) & the image file as dynamic variables generated from your 
query & display the image inside an image tag like this:

<cfquery name="GetItems">
SELECT Blah, Bleah
FROM Blah
</cfquery>

<cfoutput query="GetItems">
<img src="/images/#GetItems.category##GetItems.image#">
</cfoutput>

That would do it for you. Ive incorporated something like this into a 
shopping cart before, works like a charm.

HTH,
Mike

>From: "t nelson" <[EMAIL PROTECTED]>
>Reply-To: [EMAIL PROTECTED]
>To: CF-Talk <[EMAIL PROTECTED]>
>Subject: Is this even possible?
>Date: Thu, 14 Dec 2000 22:51:20 -0000
>
>Hi all,
>
>I am wondering if this will even be possible or if I just have a pie in the
>sky dream.
>
>Here it goes:
>
>Let's say that you have an online store with a huge inventory of products,
>we're talking close to 10'000 distinct items. your site has everything we
>have come to expect from an e-store application (search features, shopping
>carts, etc..). if by some miracle i had a good quality and not too big
>(under 10k each) .jpg or .gif for each item in my inventory. would it be
>possible for me to some how link each of those pictures to its 
>corresponding
>part in my database? this way when a customer searched for an item, a nice
>picture could come along with it.
>
>again, is this even possible, if so how?
>
>thanks in advance for your time and help,
>
>nelson
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to