Capture img info and add to div

S

Skip

Hi all,

I have created a structure for a thumbnail gallery (html / css)

Each thumb img is contained in a div class 'slide'
within the slide div is another div class 'caption'

I'm trying to find a way to automatically populate div class 'caption'
with the file name (not path ideally) of the image in the parent div
class 'slide'

I've been playing around with snippets of code found online since
yesterday but got no-where. Optionally, I would also like to populate
div class 'caption' with the alt and or title attributes.

Can anyone help?
 
A

Andreas Bergmaier

Skip said:
[...]
I've been playing around with snippets of code found online since
yesterday but got no-where.

Can anyone help?

Yes, I think so. But what isn't working, any errors? Which code snippets
do you use?

Bergi
 
J

J.R.

Hi all,

I have created a structure for a thumbnail gallery (html / css)

Each thumb img is contained in a div class 'slide'
within the slide div is another div class 'caption'

I'm trying to find a way to automatically populate div class 'caption'
with the file name (not path ideally) of the image in the parent div
class 'slide'

I've been playing around with snippets of code found online since
yesterday but got no-where. Optionally, I would also like to populate
div class 'caption' with the alt and or title attributes.

Can anyone help?

Please read this newsgroup FAQ at:
<http://www.jibbering.com/faq/#posting>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,780
Messages
2,569,611
Members
45,264
Latest member
FletcherDa

Latest Threads

Top