-
Tell Me About <div> Tag
I'm working on a website. Using CSS, I want to place a group of images (the navigation buttons) alongside a larger image. Its proving hard. I have been using the <div> function, and I'm making progress, but either the group of navigation buttons arrange themselves badly or the image I want to place next to the group of buttons gets pushed below the buttons, and won't sit alongside them.
How can I use the <div> tag to two groups of images alongside each other (please no tables)?
-
I think I can help but I'm not quite sure I understand the question. You want to have one main image (the first DIV layer), and then a group of link images in another DIV?
http://i46.tinypic.com/14qxiq.jpg
If so, the code's pretty basic; although it doesn't go into the <style> tags, it goes after the </style>.
Code:
<div style="position:absolute; top:#px; left:#px; width:#px; height:#px;">Image goes here.</div>
<div style="position:absolute; top:#px; left:#px; width:#px; height:#px;">Your navigation stuff goes here.
The "#" can be replaced by the dimensions you want.
"Top:" is how many pixels from the top the div layer is.
"Left:" is how many pixels from the left of the screen the div layer is.
"Width" is the width of the div layer, and "height" is the height, obviously.
You can play around with the numbers. Since you want the navigation div to be on the right of the picture's div, it should have a higher "Left:" number.
-
is there any html already there to look at and learn from. A quick mind can look at pre-existing HTML for a page and pull it then reassemble it while learning the whole time. Youssarian is your man to ask, he'll be able to help you here for sure.
-
Demara, that works perfectly. Thank you so much.
-
No problem. Oh, just one more thing: What Mori was talking about, you can do by going to a page of your choice and right-mouse clicking, then clicking 'view source'. It'll bring up all the coding for that page.