here the code of a currency convertor i am using in my page which is not working in firefox but works in internet explorer.
[code=javascript]<script language="javas cript" type="text/javascript">
function convert()
{
var to, from;
var to_rate, from_rate;
var quantity, result;
var temp;
to=window.f1.se lect2.selectedI ndex;
to_rate=window. f1.select2.opti ons[to].value;
from=window.f1. select1.selecte dIndex;
from_rate=windo w.f1.select1.op tions[from].value;
quantity=window .f1.amount.valu e;
if(quantity=="" )
{
window.alert("P lz specify any amount");
window.f1.amoun t.focus();
}
else if(to==from)
{
alert("Please select different currencies");
}
else
{
temp=quantity/to_rate;
result=temp*fro m_rate;
window.f1.resul t.value=result;
}
}
</script>
[/code]
you can also visite the page at www.malikexchan ge.com
[code=javascript]<script language="javas cript" type="text/javascript">
function convert()
{
var to, from;
var to_rate, from_rate;
var quantity, result;
var temp;
to=window.f1.se lect2.selectedI ndex;
to_rate=window. f1.select2.opti ons[to].value;
from=window.f1. select1.selecte dIndex;
from_rate=windo w.f1.select1.op tions[from].value;
quantity=window .f1.amount.valu e;
if(quantity=="" )
{
window.alert("P lz specify any amount");
window.f1.amoun t.focus();
}
else if(to==from)
{
alert("Please select different currencies");
}
else
{
temp=quantity/to_rate;
result=temp*fro m_rate;
window.f1.resul t.value=result;
}
}
</script>
[/code]
you can also visite the page at www.malikexchan ge.com
Comment