搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

javascript function fails in version 3.6.3, but worked in all previous versions

  • 1 个回答
  • 0 人有此问题
  • 9 次查看
  • 最后回复者为 zzxc

more options

function show_prompt(){

var cost = prompt("Please enter cost amount","");

if (cost!=null && cost!="") { document.getElementById("ncost").value = cost; document.getElementById("nno").value=1; } else { show_prompt(); } }


This function has caused no problems until i upgraded to firefox 3.6.3. The function fails to set the value of the html element until the function is called again, at which point the value from the first function call is successfully inserted.

This is obviously not workable, so i have had to backgrade to 3.5.9 so that the problem doesnt happen, but this is obviously not a long term solution.

This happened

Every time Firefox opened

== I upgraded to version 3.6.3

function show_prompt(){ var cost = prompt("Please enter cost amount",""); if (cost!=null && cost!="") { document.getElementById("ncost").value = cost; document.getElementById("nno").value=1; } else { show_prompt(); } } This function has caused no problems until i upgraded to firefox 3.6.3. The function fails to set the value of the html element until the function is called again, at which point the value from the first function call is successfully inserted. This is obviously not workable, so i have had to backgrade to 3.5.9 so that the problem doesnt happen, but this is obviously not a long term solution. == This happened == Every time Firefox opened == I upgraded to version 3.6.3

所有回复 (1)

more options

Could you link to an example that shows this code in use? From your description, I can't be sure what's happening. (My best guess is that it's prompting you twice for the cost instead of just once)