I'm trying to make some of the components in my list interactive, as there're many comments and settings depending on the user's input on the form.
The product is made out of several components, each one with their own properties, however, the product validation relies on some of the components values chosen.
I have the following js function which gets called from my view:
function change_people() {
money1 = $('money_1').children[0].value;
if (money1 == 5) {
$('comment_2').innerText = "sss";
//$('comment_2').hide();
}
else {
$('comment_2').innerText = "";
//$('comment_2').show();
}
}
document.observe('dom:loaded', function() {
change_people();
$('money_1').children[0].observe('change', change_people);
});
When I run the code in chrome, it works fine, with each selection it will update the next comment, however, in firefox is completely unresponsive!
Anyone got ideas of the reasons for this?
(oh and is using prototype library)
Thanks!