You are here: Re: 2 text alignment on the same line « HTML « IT news, forums, messages
Re: 2 text alignment on the same line

Posted by Jonathan N. Little on 11/26/85 11:55

Allerdyce.John@gmail.com wrote:
> Hi,
>
> Can someone please tell me how can I have 2 text alignment on the same
> line?
>
> I want a line where it has 'left text' to the farest left of the line
> and 'right text' to the farest right of the same line.
>
> I try below, but it does not work. It has 'left text' and 'right text'
> next to each other:
> <span style="color:purple" align="left">left text</span><span
> style="color:green" align="right">right text</span> <br/>
>
> And I try not to use Table or css float to achieve that.

Good man!

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title>Floats</title>

<style type="text/css">
..onLeft { float: left; }
..onRight { float: right; }
..below { clear: both; }
</style>

</head>
<body>
<div class="onLeft">I'm on the far left.</div>
<div class="onRight">And I'm on the far right.</div>
<p class="below">And I am below them both!</p>
</body>
</html>


--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация