idanlakritz — 2011-10-21T11:00:01-04:00 — #1
I`m trying to learn java script with the Simply java script book but i want to implement it on HTML5 web sites.
1. is the DOM different in HTML5? like I want to use the getElementsByTagName method, is it different when using an html5 page?
- are there other differences between programming Java Script for HTML5 them for XHTML??? and if so how do I overcome those differences.
thank u for helping.
felgall — 2011-10-21T15:04:48-04:00 — #2
HTML 5 is still in draft and is basically HTML 4 with lots of extra tags and attributes added (many of which are completely unnecessary and ought to be removed before it gets much further along the development process). Also since HTML 5 just uses the short version of the HTML 2 doctype there is no way of specifically identifying HTML 5. You can access it via the HTML DOM just the same as for any other version of HTML.
idanlakritz — 2011-10-21T18:30:31-04:00 — #3
I'm not really getting what ur saying, I learned HTML5 and now I'm studying java script and I want to use it on my HTML5 built site, is there a different Java script syntax that I should use than the one I would use on XHTML??
Do you have a reference to a site or article that would help me?
felgall — 2011-10-21T19:28:02-04:00 — #4
In both of those the call is retrieving all of the paragraph tags but in the case of the XHTML one it is specifying that only those that are a part of XHTML namespace re to be retrieved and that any "p" tags that exist in any other namespace within the document should be ignored as they are not paragraphs.