Forms question

A

Andy Ingall

I am creating a form on a webpage to allow visitors to
send back questions or comments. I have a drop down list
with the following choices - phone - post - email.

If the user chooses email, then i want the phone and
address fields to change colour and not be accessable to
the user. How do i do this?

Thanks

Andy
 
D

David Berry

You could do this with JavaScript. For example, create a function to change
the field(s) to Disabled or ReadOnly when there's on OnChange event for the
drop down. Something like this:

function ChangeField(){
document.all(FIELDNAME1).Disabled= true;
document.all(FIELDNAME2).Disabled= true;

}

Then on your Select box you'd have OnChange="ChangeField();"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top