I have the following javascript in MSIE:
setTimeout(myFunction, 1000, param );
this seems to work in all browsers except internet explorer. the param just doesnt get forwarded to the function. looking at the debugger, it is undefined.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
paramin Internet explorer specifies whether the code inmyFunctionis JScript, JavaScript or VBscript See also: MSDN. It does not behave like other browsers.The following will work:
The previous line does not exactly mimic
setTimeoutin Firefox etc. To pass a variable, unaffected by a later update to theparamvariable, use: