Can I spend my major time to learn HTML5 now? [closed]
Sorry,maybe it is a silly question,but I just want to know if it is a right path to study HTML5 right now? I have learned XHTML before and also PHP JavaScript.Since w3schools offering HTML5 online tutorial...
anyway,I'm not sure.Thanks guys!HTML5 just adds some more features to HTML4 you might as well learn the basics and then use them in websites from now on, however some (dumber) old browsers don't recognise the new semantics. As a web designer you may look at some of the new HTML5 features, but you can do almost anything using the old HTML4, which I recommend you learn for main use.
On another note HTML5 is more of a buzz phrase, and really couples with CSS3, some of it's new features such as time fields work in one place and not in others so it may be worth using HTML5 for the main layout semantics but not adding lots of the more specific stuff.
Just make sure any CSS3/HTML5 features you add depreciate well on IE7/8 (well IE as a whole).
Add this to your css so they are recognised and behave as they should do in older browsers.
/* HTML5 tags */
header, section, footer,
aside, nav, article, figure {
display: block;
}
As quentin mentioned in the comments the above CSS only works in more modern IE's 7+ I believe and of course doesn't make all the elements work, just the new ones designed for layout.
You could try ie7-js to make IE behave better with these new elements. http://code.google.com/p/ie7-js/ Along with HTML5-shiv http://code.google.com/p/html5shiv/
You should be learning HTML5 now. Even if you think there's dodgy browser support, you can use some really practical portions. One such example is the DOCTYPE. HTML5 has reduced it to the following:
<!DOCTYPE html>
Isn't that simple? Memorable even. Why not use it? Even if you've written your scripts to a different doctype standard, it will all still work going forward. And even if you are uncertain about the new elements, you can begin to start thinking about how you'd use them by simply using them as class names.
<body>
<div class="hgroup">
<h1>My Site Name</h1>
<h2>And Here's my Subheading!</h2>
<div class="nav">
<ul>
<li>Blog</li>
<li>About</li>
<li>Contact</li>
</ul>
</div>
<div class="article">
<p>Some blog content.</p>
</div>
<div class="article">
<p>And now I've got another blog post.</p>
</div>
</body>
Then you can begin "using" the new elements to your heart's content, styling them, and if and when you decide to make the switch, you can make your replacements quickly.
HTML in general is a basic language, and very good to have knowledge in, no matter what path in programmin you chose to go later. As the precvious answer stated, HTML5 is just an addition the previous version of the HTML language, which adds a few graphical inputs etc. If you want to work with websites, as I suppose you might, due to your knowledge of PHP XHTML and Javascript, I would definetly recommend you learning some HTML.
if you are asking if you should learn HTML5 just because w3schools is offering it. the answer is NO.
if you are into web development, or if HTML5 really interests you....YES. HTML5 is still in early stage....so you have a lot of time to learn and grow with it as it grows.
Only if your are interested in the features that HTML 5 offers, it may sound a little not worthwile at the moment as there are not many sites actually using HTML 5 this will start to change. The reason not many sites are using HTML 5 already is due to the fact that only 2 out of about 20 different browsers can understand the new HTML 5 markup.
But I do think being able to put HTML5 on your resume will help you. If not as a practical skill, then at least as a hint to potential employers that you keep up with modern techniques.
Also it maybe fun to play with it a bit as in here
精彩评论