For example, the following code:
Copy Code code as follows:
<body>
<script language= "JavaScript" >
<!--
if (document.all)
Alert ("This is a IE");
Else
Alert ("This is a Mozilla");
-->
</SCRIPT>
</body>
In IE browser will output "This is a IE";
And in Firefox browser will output "This is a Mozilla."
But this is not directly to think in Firefox is not supported Document.all property methods.
The following section of code, in IE and Firefox browser are operating normally
Copy Code code as follows:
<body>
<input type= "text" id= "TXT" value= "ddd"/>
<script language= "JavaScript" >
<!--
var v = document.all.txt.value;
Alert (v);
-->
</SCRIPT>
</body>
This is because newer FF to all do a special treatment, JS in the process of the merchant bank detected only a separate all property is, will return jsval_void (that is, false) value;
When JS in the merchant bank process detected in the form of ' if (O.P) ... ' or ' (O.P)?...: ... ', return a htmlcollection to the image.
In Google Browser, there is a double division for all, both a collection and a JS VOID (false) value.