|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| ||||||||||||||||||||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Let 's say I have this main category named About Us and is CatID1 then i have History - CatID2, Mission - CatID3, Contacts- CatID4 which fall under the main category About Us. I would like to have the same background to be displayed for the four categories and i dont want to replicate the same picture for the four categories so i just want to use one for all. Can someone pliz help me on the code.
Thanks. |
|
#2
|
|||
|
|||
|
I assume you're using ASP? Do the categories appear on the same page or on separate pages?
Why not just store the name of the image in the db at the main category level. Then write your asp page such that body background="<%=oRS("image%>" If you're not clear what I'm driving at, you'll need to give us a little more info as to how your db is currently structured and how your page is laying out |
|
#3
|
|||
|
|||
|
Thanks for the insight..i've been watching for a reply for the past week. Yeah I'm using ASP, the categories appear on individual pages that display the appropriate content. This subcategories relate to the main category using a relate field where I indicate the CatID of the main category. your suggestion on having the name of the image is an eye opener and i'm gonna try it. I'll give you a buzz on the progress. Thank you.
|
|
#4
|
|||
|
|||
|
sure. Happy to help. Shouldn't be too hard to get it to work.
In your asp page, you can hard code the file path if you put all your images in the same directory i.e., <body background="images/<%=imagename.gif%>" or you can put the full path in the db, if you use different folders. |
![]() |
| Viewing: Dev Articles Community Forums > Programming > ASP Development > displaying an image for a group of items in one category. |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|