Hope Stewart wrote:
Place each image/caption combination inside a div and float both of them to the left. As long as the combined width of the two divs isn't greater than the width of the parent element they should appear next to each other without any troubles.Help wean me from tables! I'm a WSG newbie. I created my first table-less website -- a very basic pro-bono site -- in January. It was a good learning experience, but now I'm tackling a more complicated site for a paying client and need some help.
Within the main content div, I need to include photos with captions within a grey box. When there is just one photo, I can do this. See draft:
http://www.harbourmarine.com/draft/products/capstans3.html
But most of the time I will need to have two photos side-by-side of varying sizes and with captions. Using a table, I can do this in a flash. See:
http://www.harbourmarine.com/draft/products/capstans2.html
But I believe this is an inappropriate and unnecessary use of a table. How do I replace this table with divs? There will be many product pages like this one, but the photos will vary in size.
Hope Stewart
****************************************************** The discussion list for http://webstandardsgroup.org/
See http://webstandardsgroup.org/mail/guidelines.cfm for some hints on posting to the list & getting help ******************************************************
As a side note I'd suggest doing your captions differently also. Rather than using a em/strong tag on every caption place it in a span with a class. Then apply the styles to that class. That way you don't have to write em/strong everytime you have a caption, and you can change the look of all captions easily if the need arise.
Scott Limmer ****************************************************** The discussion list for http://webstandardsgroup.org/
See http://webstandardsgroup.org/mail/guidelines.cfm for some hints on posting to the list & getting help ******************************************************