<br> and css

This is a discussion on "<br> and css" within the Web Page Design section. This forum, and the thread "<br> and css are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Sep 13th, 2007, 03:02
Junior Member
Join Date: Sep 2007
Location: Rosebud
Posts: 16
Thanks: 0
Thanked 0 Times in 0 Posts
<br> and css

Hi. I am really new to the forums and just wanderinf if i can have a bit of help.

Well i'm doing an assignment for university and its basically based around CSS. In the specifications, it says not to use the <BR> tag, and that to rely on the CSS to do this. How exactly would i do this? Is their something I can search and replace all my <br> tags with?

Many thanks
Reply With Quote

  #2 (permalink)  
Old Sep 13th, 2007, 05:52
Most Reputable Member
Join Date: Feb 2004
Location: Borneo
Age: 27
Posts: 1,608
Blog Entries: 2
Thanks: 0
Thanked 4 Times in 3 Posts
Send a message via Yahoo to Monie
Re: <br> and css

Hi lockmac,

You can use margin-top or margin-bottom to adjust the space between
elements, including paragraphs. (You can also use padding-top and
padding-bottom.)

The amount of space between paragraphs can be adjusted either a fixed
amount (as in pixels) em value, or a percentage (%) of the element size.

Code: Select all
#content h1{
margin: 0.5em 0 0.5em 0; <-- this four value refer to Top Right Bottom Left (TRBL as in Trouble :-))
}
An example of a margin adjustment in action can be seen on this page:

1. Different Paragraph
2. CSS Margin
3. Paragraph

Hope that help.
Last Blog Entry: ASP Programming Tips and Technique (Oct 26th, 2007)

Last edited by Monie; Sep 13th, 2007 at 05:57. Reason: add some sample code
Reply With Quote
  #3 (permalink)  
Old Sep 13th, 2007, 12:11
karinne's Avatar
SuperMember

SuperMember
Join Date: Jan 2007
Location: You know where
Age: 31
Posts: 4,617
Thanks: 0
Thanked 0 Times in 0 Posts
Re: <br> and css

Yep ... Monie's hit it right on the nail.


MikeHopley wrote a great article for the newsletter Semantics and he talks about the <br> element in there so you might want to check it out
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT. The time now is 07:01.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43