View Full Version : Select equivalent to alt
Hi I have a select that I want to limit to 200 px and it is working fine but now I want to show what's in the box if the text goes beyon the width of the select. (Simular to an alt for an image i guess) Is there a way I can accomplish this? Thanks for any help
link2tdss
06-23-2005, 05:35 PM
Hi
i am sorry that i do not have an answer to yor question, but the select that you mention is something i have been looking for, if it's not too much trouble can u please post the code on how to do this
Thanks a bunch
Tarun
mark87
06-23-2005, 05:44 PM
I don't think it's possible I tried both alt and title attributes and no luck in IE anyway.
link2tdss - Just do something like this -
<select>
<option>Option 1</option>
<option>Option 2</option>
<option>Option 3</option>
</select>
Then in your CSS -
select { width: 200px }
link2tdss
06-23-2005, 05:57 PM
Thanks a bunch for that mark, if you find a way around that rest of text problem do let us know, by the way is it possible to set up a scrol bar in a multi select tag, i don't think so just asking
mark87
06-23-2005, 06:03 PM
Do you mean on a select element?
I think it's browser-determined as to what number of options a scrollbar appears.
link2tdss
06-23-2005, 06:05 PM
yes i meant on a selct element, but i am not talking of a vertical scrolbar,that is browser dependent, i am talking of a horizontal scrollbar, like in an iframe,it gives a horizontal scrolbar if the text becomes too big,can it be done in the select tag also?
mark87
06-23-2005, 06:09 PM
I doubt it, try adding 'overflow:auto;' in the CSS but I don't think it'll help.
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.