js在firefox中的问题

代码在firefox中会弹出莫名奇妙的问题:

jQuery("#txtNewPassword").focus();
jQuery("#txtNewPassword").select();

alert("密码中包含不合法字符,可支持字母、数字、及\_\~\@\#\$\^符号");
正确的写法应该是:

alert("密码中包含不合法字符,可支持字母、数字、及\_\~\@\#\$\^符号");

jQuery("#txtNewPassword").focus();
jQuery("#txtNewPassword").select();

 

注意代码的顺序!

posted @ 2008-08-01 14:20 陳龑 阅读(114) 评论(0) 编辑 收藏