Loans | Credit Card Consolidation | Compare Credit Cards | Houses for Sale | Advertising
HTML line spacing [Archive] - PCMech Forums

PDA

View Full Version : HTML line spacing


TdM
04-29-2004, 07:38 AM
Guys, probably a really simple one but how do I change line spacing in HTML? I can't find a tag that works. is it something I need to add to the < p > tag??

mairving
04-29-2004, 08:13 AM
You could use Padding in CSS (http://www.w3schools.com/css/css_padding.asp)
Something like:
.classname {
padding: 10px 0px 10px 0x;
}
The first position is the top padding, then right, bottom and left.

So in your head section, you would put:
&lt;style&gt;
.spacer {
padding: 10px 0px 10px 0x;
}
&lt;/style&gt;

Then use a div like so:
&lt;div class="spacer"&gt;Some text here&lt;/div&gt;

kram 2.0
05-02-2004, 02:20 PM
CSS, eh? If you just want to do it manually, just use the line breaks tag: < br > . It's half of the paragraph tag, and it's admittedly not supposed to be used that way, but it works, doesn't it?

kram

mairving
05-02-2004, 05:24 PM
&lt;br&gt; will not really do much anything about line spacing. It will just break the line. To get non-default line spacing you would have to use CSS.

HeddaLora
05-05-2004, 07:19 PM
There are some good tutorials here:

http://www.w3schools.com/

Hedda Lora

juicelooser
05-05-2004, 07:48 PM
for line spacing with css: you'd want to use the following:

&lt;style&gt;
p {
line-height: 10px; /* adjust the 10px to whatever size you want */
}
&lt;/style&gt;

Place that in your &lt;head&gt; section.