Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

align=justify? 3

Status
Not open for further replies.

theocraticmind

Programmer
Apr 19, 2002
318
CA
is it postble to have a sort of collum align? ms word calls it "justify", it sits right beside "left", "center", and "right". it spaces all the words/letters so that they fit perfectly (or close) in the space they have.
 
u means ?
<td align=&quot;center&quot; valign=&quot;top&quot; ...
?
wmail.jpg


someone knowledge ends where
someone else knowledge starts
 
no. it's like this:

right align:
|text text |
|bfsdg d |
|dsfg d fg |
|dfggj fgjg|
|ghgfjgjf |

justified alignment:

|text text|
|bfsdg d|
|dsfg d fg|
|dfggj fgjg|
|ghgfjgjf |

i don't have the ability to space the letters, but it would. if you have MS Word and want to see what i mean check it there.
 
my code ide = notepad or vc++6

make a space
Code:
&nbsp;

just make 2
Code:
<td>
align one right the other one left
wmail.jpg


someone knowledge ends where
someone else knowledge starts
 
You can with CSS

p {text-align:justify}

This will cause all text insode a <p> tag to justify. You can add it TD, H2's or whatever

p, H2, TD, UL {text-align:justify} DeZiner
Never be afraid to try something new.
Remember that amateurs built the Ark.
Professionals built the Titanic
 
&quot;make a space&quot;
i missed the code lol
Code:
& n b s p ;
wmail.jpg


someone knowledge ends where
someone else knowledge starts
 
ok, i have somthing like this:

<table>
<tr>
<td style=&quot;text-align:justify;&quot;>
jkdfhg <br>
<br>
fghsdkhb kgbdf<br>
<br>
jkdfhg <br>
</td>
</tr>
</table>

i was hopeing that it would set the kerning(letter spacing) of the text in there. but it dosen't seem to want to.

so, dose anyone know a way of adjusting the kerning of text with css?
 
If that doesn't work, try putting a span tag inside the table cell like this:
Code:
<table>
<tr>
<td style=&quot;text-align:justify;&quot;>
<span style=&quot;text-align:justify&quot;>
jkdfhg <br>
<br>
fghsdkhb kgbdf<br>
<br>
jkdfhg <br></span>
</td>
</tr>
</table> Tracy Dryden
tracy@bydisn.com
[URL unfurl="true"]www.bydisn.com[/URL]

Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard. [dragon]
 
ya, i tried that. the justify alignment in css seems to deal with word spacing only, it never changes the letter spacing like some apps do.
 
Hi all, I'm back to the forum after 2 weeks of absence.

A few cents from me on the topic:
If we talk about <P> or <DIV> tags you don't need any styles at all to add alignment to the text.

<p align=right>
or
<p align=justify>

This will work everywhere including very old browsers.
I don't remember about <span> but it seems that it should work there too.

Kerning of text can be set using [tt]letter-spacing[/tt] property of CSS.

p { letter-spacing: 4px }

This will work in IE4+, N6.x/Mozilla, Opera 5+ but will not work in NN4.x

good luck
 
i hate NN4.x! NOTHING WORKS! well, it dosen't matter, people who use it can deal with normal right aligned text. thanks a lot, star for you.
 
hold on, if i set the font-size to a pixle value, and the td width to 100px, is there i was differant machines can see it spaced differantly?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top