BLiZZaRD
12-14-2008, 03:17 PM
Hey all, this idea I had may be better served with JS, but I don't do JS so well so I am hoping I can do something in PHP, but I am stuck at the idea stage.
What I have is a side bar on every page of the site. each page I want to give the side bar a different ID number (or something similar). I then want the script to be placed in the sidebar code and when that page is viewed it will only pull certain images/php includes etc. from a directory.
So, for ease of use sake, let's say I have a directory with 50 images. And I have 5 pages on my site. I want each page to show a different 10 images, at random (random isn't a must have) but I don't want the 10 from page 1 to ever show on page 2, etc.
I am using "image" loosely here as I will also have text/links etc. (I am not explaining this well am I?)
So is there a way to give a div an ID number that corresponds to images (or pages) to display only matching IDs in the div?
If you are as confused as I make myself sound, ask for clarification.
What I have is a side bar on every page of the site. each page I want to give the side bar a different ID number (or something similar). I then want the script to be placed in the sidebar code and when that page is viewed it will only pull certain images/php includes etc. from a directory.
So, for ease of use sake, let's say I have a directory with 50 images. And I have 5 pages on my site. I want each page to show a different 10 images, at random (random isn't a must have) but I don't want the 10 from page 1 to ever show on page 2, etc.
I am using "image" loosely here as I will also have text/links etc. (I am not explaining this well am I?)
So is there a way to give a div an ID number that corresponds to images (or pages) to display only matching IDs in the div?
If you are as confused as I make myself sound, ask for clarification.