471,852 Members | 981 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,852 software developers and data experts.

text wrap around image

Hi,
I need help in setting up a page where the text wraps around an image.
Right now, I am using table, with text in one <td> and the image in the
adjacent <td>. The problem is when the text is longer than the height of
the image, I get all this dead space below the image with the text just
going vertically down in its own <td>.
Can I use style sheet to position the image and the text so that the
text can start taking up the whole page starting from the bottom of the
image?

text text text text text text text text text text text text
+------------+
text text text text text text text text text text text text |
|
text text text text text text text text text text text text |
|
text text text text text text text text text text text text
+------------+
text text text text text text text text text text text text text text
text text
text text text text text text text text text text text text text text
text text
text text text text text text text text text text text text text text
text text

Thanks.
Jul 20 '05 #1
3 22858
Hi Xerxes,
Can I use style sheet to position the image and the text so that the
text can start taking up the whole page starting from the bottom of the
image?


try something similar:

<p>
Paragraph 1 - will be completely above the image.
</p>
<div style="float:right;">
<img ... />
</div>
<p>
Paragraph 2 - will begin beside the image and ev. float under it.
</p>

HTH,

Paul

Jul 20 '05 #2
In article <f6f8c553aa2ddb97472d75730d4408ac@TeraNews>, ashkaan57
@hotmail.com says...
Hi,
I need help in setting up a page where the text wraps around an image.


In your css:

p img { float: right; }

In your html:

<p><img src="x.jpg" alt="xx">lots of text.....
</p>

You can add margins to the image if you want.

Jul 20 '05 #3
Thank you all very much.

"Xerxes" <as*******@hotmail.com> wrote in message
news:f6f8c553aa2ddb97472d75730d4408ac@TeraNews...
Hi,
I need help in setting up a page where the text wraps around an image.
Right now, I am using table, with text in one <td> and the image in the adjacent <td>. The problem is when the text is longer than the height of the image, I get all this dead space below the image with the text just going vertically down in its own <td>.
Can I use style sheet to position the image and the text so that the
text can start taking up the whole page starting from the bottom of the image?

text text text text text text text text text text text text
+------------+
text text text text text text text text text text text text |
|
text text text text text text text text text text text text |
|
text text text text text text text text text text text text
+------------+
text text text text text text text text text text text text text text
text text
text text text text text text text text text text text text text text
text text
text text text text text text text text text text text text text text
text text

Thanks.

Jul 20 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Mark P | last post: by
2 posts views Thread by Suzanne Boyle | last post: by
2 posts views Thread by mike | last post: by
1 post views Thread by laura.paterson | last post: by
NeoPa
reply views Thread by NeoPa | last post: by
aboka
reply views Thread by aboka | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.