Search Latest topics | Adding Captions For Pictures Using CSS Fri Oct 30, 2009 2:33 am by cooldude HTML doesn't have an element that allows to insert a figure with a caption. It was once proposed (see HTML3), but never made it into HTML4. Here is one way to simulate such a figure element: <div class="figure"> <p><img src="eiffel.jpg" width="136" height="200" alt="Eiffel tower"> <p>Scale model of the Eiffel tower in Parc Mini-France </div> Then in the style sheet you use the class "figure" to format the figure the way you want. For example, to float the figure to the right, in a space equal to 25% of the width of the surrounding paragraphs, these rules will do the trick: div.figure { float: right; width: 25%; border: thin silver solid; margin: 0.5em; padding: 0.5em; } div.figure p { text-align: center; font-style: italic; font-size: smaller; text-indent: 0; } In fact, only the first two declarations (float and width) are essential, the rest is just for decoration. Comments: 0 | Statistics We have 5 registered usersThe newest registered user is JasonBreakey Our users have posted a total of 26 messages in 26 subjects Who is Online ? In total there is 1 user online :: 0 Registered, 0 Hidden and 1 Guest None Most users ever online was 17 on Mon Nov 09, 2009 4:26 am |

» Looking For Web Development Service
» Widget - How do you add them?
» AVACS LIVE CHAT
» How to Remove the Blogger Top Bar Tip and Hacks
» Blogger’s Blogspot Top 10 Hacks to Make Your Blog Better
» Lists of “Top 10” Wordpress plugins around the Internet
» WP Additions - Pagination
» CSS Styling the Header and Footer