/ Published in: HTML
Expand |
Embed | Plain Text
Comments
Subscribe to comments
You need to login to post a comment.
Nettuts on 06/25/10
33 people have marked this snippet as a favorite
themolitor
Hollow
thatryan
TwItChdw
pixelsoul
gabrield
mogwi
snippork
digitalbart
seanpowell
abir
kwameboame
visudex
kukhtenko
skidmarx
aharl
michellebracken
angel
moopee1176
petemcbride
CJness
stavros
fomigo
NathanFeeser
christianhanvey
qubestream
dayseye49
dubogii
wirenaught
wurstelite
Groobox
nairolf
moasth
Don't be frightened by the name "HTML5." This will work in all browsers -- and is what you should be using right now.
I'd recommend using the Google HTML5 javascript and adding the css styling for now, since this will not function as it should...
@gillesmaes - How will this not function as it should? Older browsers will fallback accordingly.
Certain block elements won't show properly when styled. The HTML itself is correct, but then you'll get tons of people wondering why their CSS won't work (assuming you're adding these for educational purposes) :)
Correct - but just because you use an HTML5 doctype does not mean that you have to use the new HTML5 elements. So this code specifically is perfectly fine. But yes, if you start adding the header, footer, section, article, etc. elements, you'll need to do a bit more work for cross-browser compliance.