The SitePoint Forums have moved.

You can now find them here.
This forum is now closed to new posts, but you can browse existing content.
You can find out more information about the move and how to open a new account (if necessary) here.
If you get stuck you can get support by emailing forums@sitepoint.com

If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Found the problem. You need to actually call the Javascript that you want to use. Your code never referenced the JS. Not only that, but to refernce the JS, you need to put it in a function, if you don't include it in the HTML.

So before I had an big IF to either do the first set or second set of functions - you are saying I should put that if in each function?

Well, I am going to assume that you do not have a traditional coding background here. I apologize in advance if I am mistaken.

To try and make this as short and simple without a long explanation of coding structure, basically you have 2 options using JS: you can insert it into the HTML, or you can call a function from your HTML. For something like a field-check function that will be used more than once, you should put this in a function that you can call as many times as is necessary.
That is why I put your IF stmt in a function, since you want to check more than one field. Then, you can call your function from event-handlers of the HTML tags you use.

Make sense?

Overall, glad I could help

Drew

~Drew

There Is No Greater Joy Than Soaring High On The Wings Of Your Dreams, Except Maybe The Joy Of Watching A Dreamer Who Has Nowhere To Land But In The Ocean Of Reality.