/    Sign up×
Community /Pin to ProfileBookmark

drop down list validation problem

I have form that asked this question “Please rate in order of importance using 1 as the highest and 4 as the lowest.”

It has 4 items in a list:
a. New business wins/program news
b. Recognition of employees’ accomplishments
c. President/other senior leaders’ editorials
d. Employee benefits/educational opportunities

right now I have drop down boxes at the end of each line so they can chose a number from 1 to 4. However now my boss wants to make sure they dont choose the number 2 for both line a and c, for exmaple.

Is there a way to use javascript to test what hey choose in a and not let them choose it for b, c, d, or even at least test then pop up a message if they try to use the same number?

Also I dont need to use a drop down, as long as they can choose a number between 1 to 4, I can set the numbers besides radials even.

I looked up some scripts and a “switch” seems like that would help but I am still a novice at this complex type of validation and need help.

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@JonaMar 11.2005 — [font=trebuchet ms]I'd be happy to give you a hand, but could you post the relevant HTML part of your code? (Dropdowns would probably be the best form objects to use in this case, by the way.) Also, this isn't for a school assignment, correct? (It doesn't sound like it, since you mentioned you have a boss, but you can never be too sure.)[/font]
×

Success!

Help @caws1111 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...