homepage Welcome to WebmasterWorld Guest from 107.21.187.131
register, free tools, login, search, subscribe, help, library, announcements, recent posts, open posts,
Subscribe to WebmasterWorld

Home / Forums Index / Code, Content, and Presentation / HTML
Forum Library, Charter, Moderators: incrediBILL

HTML Forum

    
What is the <br /> tag?
Rightz




msg:580518
 10:43 am on Jun 4, 2006 (gmt 0)

I have seen this is a couple of websites recently and it means nothing to me. I searched google and found nothing on it.

What on earth does the <br /> tag do or mean?

 

Acekicker




msg:580519
 10:49 am on Jun 4, 2006 (gmt 0)

It breaks the line. If you put <br />
then your text will go to the next line down.

larryhatch




msg:580520
 10:58 am on Jun 4, 2006 (gmt 0)

That's what the <br> tag does, without the slash, it forces a line break.

Is there any difference between <br> and <br/> though? -Larry

abbeyvet




msg:580521
 11:01 am on Jun 4, 2006 (gmt 0)

<br> is not valid xhtml.

<br /> is.

It only matters if you are using xhtml

[edited by: abbeyvet at 11:02 am (utc) on June 4, 2006]

Acekicker




msg:580522
 11:01 am on Jun 4, 2006 (gmt 0)

"That's what the <br> tag does, without the slash, it forces a line break.

Is there any difference between <br> and <br/> though? -Larry"

No, none.

larryhatch




msg:580523
 11:03 am on Jun 4, 2006 (gmt 0)

I use <br> a lot. I'll just leave out the slash, a useless extra byte of bandwidth then.

Rightz




msg:580524
 2:09 pm on Jun 4, 2006 (gmt 0)

Ah that clear it up then. Im not using xhtml so <br> is the only thing I use.

dddddd




msg:580525
 12:21 pm on Jun 5, 2006 (gmt 0)

Yes <br> and <br/> are the same when using plain HTML. For simplicity I just use <br>.

Lidija Turkovic

piatkow




msg:580526
 8:10 pm on Jun 6, 2006 (gmt 0)

Personally I try to future proof all my code so as I edit or create new pages I try and close all tags and make sure all tags are lower case.

SonjaD




msg:580527
 11:10 am on Jun 20, 2006 (gmt 0)

You can also look at it from the other side.

<br> is correct html 4.01
<br/> is not

So futureproofing isn't doing a lot of good.

If and when you go to XHTML just search and replace all <br> to <br/>

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / HTML
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved