473,395 Members | 1,872 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

aligning text to image

Dear NG-readers,

I want to align text right to an image. The last line of text should
align with the bottom edge of the image. Unfortunately, the results
using my poor CSS knowledge mounted in text which starts at the bottom
line of the image and continues below. For an example go here:
http://tomasio.at/temp/test_valign.html

I want to achieve the following look:
http://tomasio.at/temp/correct.html

Does anybody could give me a hint what I am doing wrong?

kind regards,
--
tomasio
Feb 27 '06 #1
6 1996
Once upon a time *tomasio* wrote:
Dear NG-readers,

I want to align text right to an image. The last line of text should
align with the bottom edge of the image. Unfortunately, the results
using my poor CSS knowledge mounted in text which starts at the bottom
line of the image and continues below. For an example go here:
http://tomasio.at/temp/test_valign.html

I want to achieve the following look:
http://tomasio.at/temp/correct.html

Does anybody could give me a hint what I am doing wrong?

kind regards,


Something like this may work?

<div class="indent"> <img src="images/jan_bild.jpg"
style="float: left; margin-right: 10px;" alt="image" height="150"
width="145">
<p style="margin-top: 60px;">this text
should float the image on theleft side, but the last line of text
should end with the bottom line of
the image.</p>
</div>

--
/Arne

Now ignoring all top posters
* How to post: http://www.cs.tut.fi/~jkorpela/usenet/brox.html
-------------------------------------------------------------
Feb 27 '06 #2
On Mon, 27 Feb 2006 15:17:20 +0100, Arne <in*****@domain.invalid>
wrote:
Once upon a time *tomasio* wrote:
Dear NG-readers,

I want to align text right to an image. The last line of text should
align with the bottom edge of the image. Unfortunately, the results
using my poor CSS knowledge mounted in text which starts at the bottom
line of the image and continues below. For an example go here:
http://tomasio.at/temp/test_valign.html

I want to achieve the following look:
http://tomasio.at/temp/correct.html

Does anybody could give me a hint what I am doing wrong?

kind regards,


Something like this may work?

<div class="indent"> <img src="images/jan_bild.jpg"
style="float: left; margin-right: 10px;" alt="image" height="150"
width="145">
<p style="margin-top: 60px;">this text
should float the image on theleft side, but the last line of text
should end with the bottom line of
the image.</p>
</div>

Thanks a lot, Arne, that is a step towards the solution of the desired
layout. The problem is, as soon as the text is changing in its size,
the alignment is not correct any more. Is there a possibility to keep
the text to the bottom edge of the image no matter what amount of text
I enter?

kind regards,
--
tomasio
Feb 27 '06 #3
tomasio <fr*********@bled.de> wrote:
I want to align text right to an image. The last line of text should
align with the bottom edge of the image. Unfortunately, the results
using my poor CSS knowledge mounted in text which starts at the bottom
line of the image and continues below. For an example go here:
http://tomasio.at/temp/test_valign.html

I want to achieve the following look:
http://tomasio.at/temp/correct.html


<title>CSS Tutorial</title>?

Doing this "properly" requires browser support for CSS tables (not
supported by IE): http://homepage.ntlworld.ie/spartanicus/temp.htm

--
Spartanicus
Feb 27 '06 #4
On Mon, 27 Feb 2006 14:33:06 +0100, tomasio <fr*********@bled.de>
wrote:

: Dear NG-readers,
:
: I want to align text right to an image. The last line of text should
: align with the bottom edge of the image. Unfortunately, the results
: using my poor CSS knowledge mounted in text which starts at the bottom
: line of the image and continues below. For an example go here:
: http://tomasio.at/temp/test_valign.html
:
: I want to achieve the following look:
: http://tomasio.at/temp/correct.html
:
: Does anybody could give me a hint what I am doing wrong?
If it were me, I would use tables. Of course I use CSS as well, but
for this application, what could be simpler?

<table cellpadding=6>
<tr>
<td>the image</td>
<td valign=bottom>the text</td>
</tr>
</table>

Set width of TDs and Table to taste. Serves a good page.

Sid


Feb 27 '06 #5
On Mon, 27 Feb 2006 15:33:06 GMT, Spartanicus
<in*****@invalid.invalid> wrote:
tomasio <fr*********@bled.de> wrote:
I want to align text right to an image. The last line of text should
align with the bottom edge of the image. Unfortunately, the results
using my poor CSS knowledge mounted in text which starts at the bottom
line of the image and continues below. For an example go here:
http://tomasio.at/temp/test_valign.html

I want to achieve the following look:
http://tomasio.at/temp/correct.html


<title>CSS Tutorial</title>?

Doing this "properly" requires browser support for CSS tables (not
supported by IE): http://homepage.ntlworld.ie/spartanicus/temp.htm


thx a lot, Spartacus. It's a shame that IE does not render CSS tables,
but at least it displays correctly in Firefox.

kind regards,
--
tomasio
Feb 27 '06 #6
On Mon, 27 Feb 2006 18:08:29 +0200, Sid Ismail <el***@nospam.co.za>
wrote:
If it were me, I would use tables. Of course I use CSS as well, but
for this application, what could be simpler?

<table cellpadding=6>
<tr>
<td>the image</td>
<td valign=bottom>the text</td>
</tr>
</table>

Set width of TDs and Table to taste. Serves a good page.

Sid


In this case it is the most simple approach. Sometimes these tables
are still useful ; )

Thank you for your help.

kind regards,
--
tomasio
Feb 27 '06 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: junior | last post by:
Hi group, I have a problem with a small project i'm doing at the moment. Here's my code below. <table width="668" height="63" border="0" cellpadding="0" cellspacing="0"> <tr> <td...
1
by: Graham Cross | last post by:
Dear All Is there an HTML way of aligning the images on this page http://www.ageconcernleics.com/review03/chairs03.html so that they appear evenly spaced relative to the text column on the...
1
by: Larry Viezel | last post by:
http://nominex.com/bottomalign.htm I am viewing this page in IE. The expected behavior is that the image will align to the bottom of the div and that the text will wrap around the image. But...
10
by: Carolyn Marenger | last post by:
I think this is an easy one, but I have not been able to find it anywhere. In HTML, I used <center><img src="whatever.gif></center> to horizontally center a graphic on a page. What is the CSS...
0
by: Paul E Collins | last post by:
Hello. I want to display a number of individual blocks of text. Each block has an associated image, which should be displayed on the right and aligned with the top of its block of text, i.e....
7
by: lilOlMe | last post by:
I'm designing a sort of error message screen. Well it's not a screen...its just a <div> that displays the error messages and allows the user to close it (or drag it around etc.) The title...
2
by: agbee1 | last post by:
Hello: I've finally made the effort to ween myself from overly using tables and use CSS for my positioning. However, I am having a problem with my navigational menu properly aligning in Firefox,...
14
by: gaijinco | last post by:
I was a hobbist web coder for years but I had to sidestep for a while. Now I'm trying to return to it and I'm trying to clarify how am I supposed to do somethings with CSS v.s. HTML and I'm...
10
unstoppablekatia
by: unstoppablekatia | last post by:
I have a website that has images on it, and underneath the images are text. My only option of aligning the images and text separate from each other, is to do <div align="right">, <center>, or <div...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.