Home > Web Front-end > JS Tutorial > body text

Test code with missing semicolon in cssText return value only under IE6/7/8_javascript skills

WBOY
Release: 2016-05-16 18:09:33
Original
1038 people have browsed it

Test code:


[Ctrl A select all Note: If you need to introduce external Js, you need to refresh to execute
]


The output of each browser is as follows
IE6/7/8:

Test code with missing semicolon in cssText return value only under IE6/7/8_javascript skills

IE9/Firefox/Chrome/Safari/Opera :

Test code with missing semicolon in cssText return value only under IE6/7/8_javascript skills

You can see that the semicolon is missing in IE6/7/8. Be careful when using the cssText property. <script> var div = document.getElementsByTagName('div'); alert(div[0].style.cssText); </script>
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template