navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

Microsoft MVP

 

p p p paragraphs

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> Cascading Style Sheets >> p p p paragraphs
Page: [1]
 
yogaboy

 

Posts: 377
Joined: 5/22/2004
Status: offline

 
p p p paragraphs - 8/17/2005 18:43:55   
Hello all,

Quick (i hope) quiz for you.

I want to get rid of the carriage-return added on the end of a paragraph by the <p> tags. I've tried using

p {margin: 0;}

or

p {margin-top:0; margin-bottom:0;}

but neither has worked. How do I get rid of the carriage-return???!!!!:)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: p p p paragraphs - 8/17/2005 18:47:53   
Bit late so my brain's not working well (so I can't guarantee it'll work), but try:

p { margin:0px; padding: 0px; }

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to yogaboy)
Spooky

 

Posts: 26597
Joined: 11/11/1998
From: Middle Earth
Status: offline

 
RE: p p p paragraphs - 8/17/2005 21:06:24   
Use <br /> :)

_____________________________

If you arent part of the solution, then there is good money to be made prolonging the problem

§þ:)


(in reply to womble)
yogaboy

 

Posts: 377
Joined: 5/22/2004
Status: offline

 
RE: p p p paragraphs - 8/17/2005 23:06:14   
p {margin: 0em 0 0 0;} is what worked in the end. Ta for the help.

Can't use a <br /> cuz then it won't be w3c xhtml compliant, and we do love our compliancy here at Outfront! :)

(in reply to Spooky)
Spooky

 

Posts: 26597
Joined: 11/11/1998
From: Middle Earth
Status: offline

 
RE: p p p paragraphs - 8/17/2005 23:11:44   
<austin powers>Oh behave! :)</austin powers>

Im not going to go there :)

_____________________________

If you arent part of the solution, then there is good money to be made prolonging the problem

§þ:)


(in reply to yogaboy)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: p p p paragraphs - 8/18/2005 6:26:34   
quote:

Can't use a <br /> cuz then it won't be w3c xhtml compliant, and we do love our compliancy here at Outfront!


You can use <br /> and be xhtml strict compliant. I use it often and the pages I use it on are compliant.

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to yogaboy)
yogaboy

 

Posts: 377
Joined: 5/22/2004
Status: offline

 
RE: p p p paragraphs - 8/18/2005 7:03:08   
But all text has to be wrapped in p tags, and I don't want that extra space at the bottom so I can't just finish with a br and hope to get away with it. They're so strict at w3c <austin>Yeah baby, yeah!:)<austin>

<rant>
Personally I don't see why any tags should add in little "extras", I thought this was against the principles of xhtml, seperating the design from the content. Why should <h3> add a line? Why should <p> add a line? Having to remove these via css is the exact opposite of what w3c say they are doing! In my eyes, p and h are content tags.
</rant>

(in reply to womble)
davidrandall

 

Posts: 82
Joined: 7/28/2005
Status: offline

 
RE: p p p paragraphs - 8/18/2005 7:33:23   
On your next build, why not try the global white space reset at the beginning of your style sheet:
* {
	padding: 0;
	margin: 0;
}

Then you can add margins, padding etc to only those elements you choose.

Dave

(in reply to yogaboy)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: p p p paragraphs - 8/18/2005 7:39:20   
Iain, I agree with your <rant> to a certain extent. Valid xhtml and css should be about trimming out superfluous content that isn't required, but (and I know this isn't the right forum) adding white space between paragraphs aids accessibility. More white space makes it easier to read paragraphs, whether you have visual problems or not.

I recently did a page with a poem on it, and of course I needed a new line every so often, but I didn't want too much space between them. The lines were pretty short and using a closing </p> tag at the end of each line made the whole thing look ridiculous, so I ended up using <br /> at the end of the lines and simply adjusting the space round the whole thing using css. Removing the extras via css is a hassle, yes, but the general principle of having space between paragraphs is a good one.

I may be wrong, but I don't think it's the W3C that add in the space between paragraphs and headings etc., it's the browsers and how they interpret the tags. The poem I mentioned earlier - the biggest hassle was finding a happy medium for the white space around it because of the differences in how FF and IE rendered it, but browser differences is another rant entirely. :)

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to yogaboy)
Page:   [1]

All Forums >> Web Development >> Cascading Style Sheets >> p p p paragraphs
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts