Limiting width of <select> box

M

Manny Klystron

How do I peg the width of the box generated by a <select> tag, clipping

<options> that're too long for it? It's turning out to be difficult to

google for.

This is IE6, IE7, Safari. IE7 is ignoring the "clip: rect{}" style.
Options are generated in code, so I could do a measure there and clip
by hand, but I wouldn't think I'd need to.


Thanks!
 
A

Adrienne Boswell

How do I peg the width of the box generated by a <select> tag,
clipping

<options> that're too long for it? It's turning out to be difficult to

google for.

This is IE6, IE7, Safari. IE7 is ignoring the "clip: rect{}" style.
Options are generated in code, so I could do a measure there and clip
by hand, but I wouldn't think I'd need to.


Thanks!

There isn't much you can do for this. You can try setting the width in
CSS, but that doesn't always work. If the list is generated server
side, that's your best bet. Actually, this is something I very rarely
worry about, if it's wide, it's wide, that's just the way the cookie
crumbles. You might be able to move some other form elements around to
accomodate it.
 

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,755
Messages
2,569,536
Members
45,020
Latest member
GenesisGai

Latest Threads

Top