I want to be able pass a validated value back to a form without explicitly
assigning the value in JS and I can't figure it out or even whether it can
be done. Something like:

<input type="text" name="field1" value="na"
onChange="javascript:validate(this)">

Then in js have:

function validate(obj){
        if (document.formName.obj.value == "field1"){
                document.formName.ojb.value = 1;
                }
        else{
                document.formName.obj.value = 2;
                }
        }


When I do this I get errors saying that "document.formName.obj has no
properties".

Thanks
Duncan Hays
Peace Corps
------------------------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists or send a message 
with 'unsubscribe' in the body to [EMAIL PROTECTED]

Reply via email to