如何使Java脚本在剩余的所有浏览器中的mozilla firefox中工作 [英] how to make java script to work in mozilla firefox remaining all browsers
本文介绍了如何使Java脚本在剩余的所有浏览器中的mozilla firefox中工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好...
我有这样的脚本:
hi all...
i have script like this:
<script type="text/javascript">
function count(txt)
{
var textchar='<%= TextBox2.MaxLength %>';
var textbox=document.getElementById(txt);
var lbl=document.getElementById('<%= Counlbl.ClientID %>');
if(textbox.value.length>textchar)
{
textbox.value=textbox.value.substrung(0,textchar);
}
lbl.innerText=textchar-textbox.value.length+" Characters remaining..";
}
</script>
此脚本可以在Internet Explorer中工作,但不能在Mozilla Firefox中工作,我也把最大长度设为120个字符,但是在超过长度后会引发异常1.如何防止这种异常2.如何使此脚本在Firefox中可以工作?请帮助我
在此先感谢
this script working in internet explore but not working in Mozilla Firefox and also i put max length as 120 characters it raises exception after crossing length 1.how can i prevent this exception 2.how can i make this script to work in Firefox can any one please help me
Thanks in Advance
推荐答案
^ ]
您应提供 Ajax-Frameworks [ ^ ]. .
[argh ...不是母语人士]
You should give Ajax-Frameworks[^] a try...
[argh... not native speaker]
这篇关于如何使Java脚本在剩余的所有浏览器中的mozilla firefox中工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文