...

View Full Version : Using Paragraph Tags as a layout mechanism



missing-score
03-06-2004, 09:44 PM
Right, simple question. I am making a design and I have got points where I use:

<p></p>

just to break something up and leave a gap.

Is this use of a paragraph tag considered ok? or should I be using another method?

spl1nter
03-06-2004, 09:50 PM
The paragraph tag is supposed to be used to group a selection of words in (surprise, surprise) a paragraph.

You could probably use it to break stuff up, but you should probably use <br />

missing-score
03-06-2004, 09:54 PM
Trouble is, <br /> is only acceptable within a paragraph tag, and I am not within a paragraph tag when Im wanting to use <p></p> to break up the content.

spl1nter
03-06-2004, 09:55 PM
<p>
...blah blah blah...<br /><br />

...blah blah blah...<br /><br />

...blah blah blah...<br /><br />

...blah blah blah...<br /><br />

...blah blah blah...<br /><br />
</p>

missing-score
03-06-2004, 11:01 PM
I understand what you mean, but my design is like:


<div>
<p>Text</p>
<div ....>
<p>Text 2</p>
</div>
<p></p>
<div>
<p>.....</p>
</div>
</div>

Antoniohawk
03-06-2004, 11:15 PM
I don't even think that <br /> is the best way to go. The ultimate solution would be to add a margin-bottom to the div.

missing-score
03-06-2004, 11:18 PM
Ive thought about that, however it seems to cause some problems when I have tried it before degrading with IE 5... Or am I thinking of padding... I will have a go.

Antoniohawk
03-06-2004, 11:23 PM
Not sure, but you may have to implement the box model hack found in my signature for ie's deficiencies.

missing-score
03-06-2004, 11:35 PM
thanks ill look into it

mindlessLemming
03-07-2004, 01:08 AM
Def. go with margin. Introducing empty <p> tags for margins is as bad as empty table cells for the same thing.

The issues in IE 5 should be simple to navigate; post if they aren't.

me'
03-07-2004, 09:46 AM
No tags should be used at all if it adds nothing to the content.

Antoniohawk
03-07-2004, 07:35 PM
Exactly what me' said :thumbsup:

missing-score
03-07-2004, 08:17 PM
Is that the whammy technique I have heard about?



Just apply the Whammy-technique : reply to all threads with "morder/spookster/raf is right ..."


or in this case me'



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum