Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

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

  • 1 reply
  • 0 have this problem
  • 9 views
  • Last reply by 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

All Replies (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)