Something went wrong. Try again.
Reactos
Something went wrong. Try again.
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849<html><head><script type="text/vbscript"><!--Dim counter
counter = 1
Sub ok(b,m) Call external.ok(b,m)End Sub--></script><script>' Verifies that we're in VBScript although there is no type specifiedIf true then counter = counter+1function inccounter(x) counter = counter+xend function</script><script type="text/javascript">// We're in javascripttry { counter++; incCounter(2);}catch(e) { ok(false, "got an exception " + e.message);}</script><script>' And back to VBScriptIf true then counter = counter+1
Sub runTest() Call ok(counter = 6, "counter = " & counter) Call ok(isNull(document.onkeyup), "document.onkeyup is not null") Call ok(document.formname.tagName = "FORM", "document.form.tagName = " & document.formname.tagName) Call ok(formname.tagName = "FORM", "form.tagName = " & formname.tagName) Call external.reportSuccess()End Sub</script><script type="text/javascript">// We're in javascript</script><body onload="If true then runTest()"><form name="formname"></form></body></html>