I'm trying to say in my code below that when field1.value is input, populate field2 with that value/text. this is being done through an on change event, but its not running the way I think it should.
this works:
if (field1.value=='Hello') {field2.value='World'} else {field2.value='foo';}
but I'm trying to get the below to work and its not:
if (field1.value=='%') {field2.value='field1.value'} else {field2.value='';}
Aucun commentaire:
Enregistrer un commentaire