Help - Search - Members - Calendar
Full Version: Break
Movable Type Community Forum > Additional Resources > Tips and Tricks
Jabbok
When adding a break in the templates or in a post do you use
CODE
<br>
or
CODE
<br />
?

Thanks....
charle97
i use
CODE
<br />
Tom Alday
CODE
<br />

is XHTML compliant
Jabbok
I do too but I get errors on it when I run it through the W3C validator.

Thanks....
dbabbage
The choice is due to chances from HTML 4.01 to XHTML. As the current versions of MT produce XHTML 1.0 Transitional code, you should technically be using:
CODE
<br />

though in fact either will work just fine in all modern broswers currently.

Similiarly, you should close all image tags with:
CODE
<img src="http://url.of.your.image" alt="Short description" />

if you're going to be correct about it.
smile.gif
maddy
QUOTE (Jabbok @ Jan 5 2004, 12:40 PM)
I do too but I get errors on it when I run it through the W3C validator.

What errors? What DOCTYPE do you have in the head of your documents? smile.gif
Jabbok
Here is the DOCTYPE at the top of my pages:
CODE
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Thanks for the tip on the images. I had seen that done and wasn't sure about it.
I got a bunch of the little red arrows pointing to the breaks in the validator. I don't remember what the error message was. I'll check again....
LisaJill
post your web url and we can have a look too... =)
Jabbok
OK...you asked for it.

My Webpage

If you want to run that through the validator and explain to me how to fix some of that stuff I would appreciate it. Remember, you asked tongue.gif

Thanks...
LisaJill
319 errors, but most of the errors are easy to fix.

The first thing you should do is go through your html pages and make absolutely sure that *everything* tag-wise is lowercase. You have a lot of width="blah" and height="blah" type tags that say WIDTH and HEIGHT, those need to be lowercase.

Anytime you have an ampersand, you need to escape it for it to validate, so it needs to be

CODE
&amp;


you have a lot that are not encoded, so change any

CODE
&


to the above.

You also have a ton of

CODE
<BR>
and
<br>


tags. those all need to be:

CODE
<br />


another one thats getting you a lot is all of your image tags need to be in the format

CODE
<img src="pathtoimage/nameofimage.jpg" alt="blah" width="100" height="100" />


changing the proper variables.

once you have those cleaned up you should be down to only a few errors, and can clean it up from there.

i'm more than happy to help with validating as long as you can stand it *grins* can contact me on im as well if you want. =)

does that help?
Jabbok
My goodness....where have you been all my life!

Thanks for the help....

smile.gif
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.