emberfly
Jul 30 2009, 04:20 PM
ok.. I've always been taught to use
CODE
<BR>
but ever since I started making Xanga layouts, I've seen some people use
CODE
<BR />
Wthell is the point in that? Why not just use the first one?
Also, I was reading this:
http://line25.com/articles/10-html-tag-cri...shouldnt-commitand I have some questions.
........
on all of them actually

except the last one. That one is obvious.
tcunningham
Jul 30 2009, 04:23 PM
He explained each one, in pretty good detail below the examples. You should use <br /> in XHTML, becuase it needs to have the closing tag, in HTML, there is no need for <br> to have a closing tag. It's just the difference between HTML, and XHTML.
emberfly
Jul 30 2009, 04:24 PM
Oh. Yes, I know he wrote stuff under each one, but he didn't explain WHY we should be doing this :P or why it's better than the other way.
tcunningham
Jul 30 2009, 04:29 PM
summary: there's a time and place for everything. You're a grammar freak, so think of it as punctuation. coding can be the same way, there is a certain way that the markup should be written, you can't go willy-nilly putting whatever tags you want, and how you want them. It won't pass validation if you do that.
emberfly
Jul 30 2009, 04:30 PM
What is this "validation" you speak of?
tcunningham
Jul 30 2009, 04:41 PM
emberfly
Jul 30 2009, 04:42 PM
Thank you, Thomas.
fixtatik
Jul 30 2009, 05:03 PM
Validation is technically a guideline. If a site works, it works. You might have some custom tags that won't pass W3C validation, but they'll work because you defined them on your own. Take a look at Myspace, for example. The site works, even with an average of over 100 errors on every page, some going beyond 300 errors.
The big thing to note on the difference between HTML and XHTML is the case-level. HTML tags can be either uppercase (<HTML>) or lowercase (<html>), but XHTML must always be lowercase.
The slash in <br /> is because it's an empty element, like <img /> or <link /> or <input />. Without the slash, it's like using <div> but never using </div>. That said, you can also use <br></br> or <img></img> and it will still validate.
emberfly
Jul 30 2009, 05:17 PM
I never knew you had to close <br> tags O_o (or image tags)
oddddddd
Mike
Jul 30 2009, 05:44 PM
This good for closing then?
emberfly
Jul 30 2009, 05:49 PM
yes
Mike
Jul 30 2009, 05:50 PM
Topic closed & moved.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please
click here.