how would a user like these options

V

VisionSet

I have a small number (lets say 3) mutually exclusive ranges that I require
the user to select zero or one of.

eg:
0-9
A-Z
a-z

so the user could ignore the <select>s (or whatever)
or choose *one* of the following for example:

3-7
B-T
p-r

How would you presnt this to the user / what would the user expect?

I could put them all in one pair of <select>s but then you could get eg 5-M
I guess I could do this and return errors, or convert 5-M to 5-9 or A-M
explaining to the user what happened, but is there any other approach?
 
S

SeeSchloss

I have a small number (lets say 3) mutually exclusive ranges that
I require the user to select zero or one of.

eg:
0-9
A-Z
a-z

so the user could ignore the <select>s (or whatever)
or choose *one* of the following for example:

3-7
B-T
p-r

How would you presnt this to the user / what would the user
expect?

I could put them all in one pair of <select>s but then you could
get eg 5-M I guess I could do this and return errors, or convert
5-M to 5-9 or A-M explaining to the user what happened, but is
there any other approach?

Maybe you could prevent the user to choose different types
with javascript, for example when you select a digit in the
first <select>, only digits appear in the second ?
Or three <select>s : the first one to choose between
digits/capital letters/miniature letters, and the other
ones would display only the type selected in the first one
?

But don't ask me how to do this :p
 
J

Jukka K. Korpela

VisionSet said:
I have a small number (lets say 3) mutually exclusive ranges that I
require the user to select zero or one of.

eg:
0-9
A-Z
a-z

Sounds like a job for checkboxes.
so the user could ignore the <select>s (or whatever)
or choose *one* of the following for example:

Pardon? How does this relate? And please explain the real problem, it'll
be much more understandable than the dummy example.
I could put them all in one pair of <select>s but then you could get
eg 5-M I guess I could do this and return errors, or convert 5-M to
5-9 or A-M explaining to the user what happened, but is there any
other approach?

Sorry, the formulation is far too confusing.

Anyway, in HTML forms, you can do very simple things only. It sounds you
need to tell users to select so-and-so _or_ so-and-so, and to check in the
form handler that an acceptable selection has been made. If you have spare
time, you could later add client-side pre-checking, but it would be
somewhat redundant: if you give simple instructions, and the user ignores
them, it's fair to throw some error message from the form handler, without
trying to catch the problem client-side.
 
C

Chris Morris

VisionSet said:
I have a small number (lets say 3) mutually exclusive ranges that I require
the user to select zero or one of.
3-7
B-T
p-r

How would you presnt this to the user / what would the user expect?

No idea what the user would _expect_, it's not something I've seen
before. However, the idea below is based on something similar, and
users seem fine with it.
I could put them all in one pair of <select>s but then you could get eg 5-M
I guess I could do this and return errors,

Simplest on the form, at least.
or convert 5-M to 5-9 or A-M

Which one - it's arbitrary, I'd advise against it.
explaining to the user what happened, but is there any other approach?

[radio] None
[radio] Numeric From [select] To [select]
[radio] Lowercase From [select] To [select]
[radio] Uppercase From [select] To [select]

The selects only have the appropriate thing for their range, the radio
button chooses which select to parse (if any). Obviously you also
have to make sure your server-side process deals with a range like R-G
properly. Exactly what properly *is* depends on the application.
 
V

VisionSet

[radio] None
[radio] Numeric From [select] To [select]
[radio] Lowercase From [select] To [select]
[radio] Uppercase From [select] To [select]

The selects only have the appropriate thing for their range, the radio
button chooses which select to parse (if any). Obviously you also
have to make sure your server-side process deals with a range like R-G
properly. Exactly what properly *is* depends on the application.

Naturally. It transparently inverts the range.

Thankyou, I hadn't considered that one.
I could also ditch the '[radio] none'.
Another is to have the 3 sets of selects and the 1st <option> being a 'not
selected'.
I quite like the JS idea posted by SeeSchloss too.
 
C

Chris Morris

VisionSet said:
Chris Morris said:
[radio] None
[radio] Numeric From [select] To [select]
[radio] Lowercase From [select] To [select]
[radio] Uppercase From [select] To [select]

I could also ditch the '[radio] none'.

Worth keeping it, I think, since it gives a sensible default state for
the user, and an easy way to tell if they accidentally pressed submit
too early.
Another is to have the 3 sets of selects and the 1st <option> being a 'not
selected'.

What do you do if a user uses two of them? The radio button makes it
explicit that they can only select one range, and makes it easier to
process in the server-side too.
I quite like the JS idea posted by SeeSchloss too.

If you use that, make sure it's usable without JS, and your
server-side process is able to reject bad pairs anyway.
 

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

Members online

Forum statistics

Threads
473,754
Messages
2,569,527
Members
44,998
Latest member
MarissaEub

Latest Threads

Top