In the recent MD page, we need to consider ff and IE, so a lot of JS will have some problems.
It is best to use W3C standard L for coding.
<! -- This is the IE Method -->
<SCRIPT defer type = "text/JavaScript">
Subdate ();
</SCRIPT>
<SCRIPT type = "text/JavaScript">
// This is the FF Method
If (document. addeventlistener)
Document. addeventlistener ("domcontentloaded", function () {subdate () ;}, null );
</SCRIPT>
You can also:
<SCRIPT type = "text/JavaScript">
If (document. addeventlistener)
Document. addeventlistener ("domcontentloaded", function () {choose () ;}, null );
Else
Window. onload = choose;
</SCRIPT>
This is an event executed after the IE and FF pages are loaded.
Innertext does not have this attribute in ff. The corresponding attribute is textcontent.
The following is to determine whether it is IE
If (navigator. appname. indexof ("Explorer")>-1)
Document. getelementbyid ("XX"). innertext = "xxxxxx ";
Else
Document. getelementbyid ("XX"). textcontent = "xxxxxx ";
Innerhtml compatibility