Is innerHTML standards compliant?

I read that innerHTML is "non W3C DOM" and I have no idea what that means....

Should I use this or is there a better method?  I want to alert the text found in a div.

My code works but I want to make sure it meets standards.
<div id="m52371426">Hello World</div>
<script type="text/javascript">

Open in new window

LVL 16
Who is Participating?
ZippitConnect With a Mentor Commented:

innerHTML is not a part of the W3C DOM specification. However, it is supported by all major browsers.
Even when it is non W3C DOM about every major browser supports it. Why not use it?
hankknightAuthor Commented:
Is there a W3C approved alternative?
RoonaanConnect With a Mentor Commented:
Probableto manually parse all childnodes...
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.