Is there a way to put a paragraph next to a parargraph? (Full Version)

All Forums >> [Web Development] >> Expression Web Help



Message


paul1912005 -> Is there a way to put a paragraph next to a parargraph? (11/5/2007 4:40:11)

I'm trying to put two paragraphs next to each other using webexpression but not sure how to it.

I have two pictures left and right and would like to put text under them but in different paragraphs.

Any suggestions?




Tailslide -> RE: Is there a way to put a paragraph next to a parargraph? (11/5/2007 5:20:21)

You'd want to put the photos and text within a div and then float them next to each other. So you'd have:

HTML:
<div class="box">
    <img src="yourphoto.jpg" width="200" height="220" alt="your photo" />
    <p>Photo 1</p>
</div>

<div class="box">
    <img src="yourphoto1.jpg" width="200" height="220" alt="your other photo" />
    <p>Photo 2</p>
</div>


CSS:
.box {float:left;width:200px;margin-right:10px;border:1px solid;}


The border's just there so that you can see what you're doing - you can obviously remove that. When floating divs you must specify a width so just use the width of the widest photo.




Page: [1]

Valid CSS!




Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI
0.0625