All pastes #338409 Raw Edit

molexus

public javascript v1 · immutable
·published 2007-02-03 12:27 UTC
rendered paste body
var daysdisc;  var daysdisc;  var costdisc;  function init(){  daysdisc = document.forms['reservation'].elements['daysdisc'];  qtydisc = document.forms['reservation'].elements['QuantityStandardScooter'];  costdisc = document.forms['reservation'].elements['costdisc'];  }function doTheMath(x){ if(x == 1){  if(daysdisc.value <= 3) costdisc.value = 75 * daysdisc.value * qtydisc.value; }}function checkstate(){ if (daysdisc.value != ''){  if(qtydisc.value != ''){   //doTheMath(1);   alert  } }}window.onload = init();