0

is there anyway for the title in option tag to be displayed always?

<select>
<option title="sometitle" value="">1</option>
</select>

any ideas please?

Thanks

BalusC
  • 1,082,665
  • 372
  • 3,610
  • 3,555
JPro
  • 6,292
  • 13
  • 57
  • 83
  • 1
    You want a series of overlapping tooltips to be permanently displayed on select elements? (Probably not, but your question could really do with clarification… and that said, the title attribute is designed to provide advisory information, if it is important enough to display "all the time" then it almost certainly shouldn't be in the title attribute in the first place) – Quentin Nov 30 '09 at 14:48
  • I am restricting the size of select, so I want the user be able to see long text that has been truncated in the title tag, as it gets disoplayed when the user hovers the mouse on the option – JPro Nov 30 '09 at 15:00

3 Answers3

1

Should be:

<select title="sometitle">
    <option value="">1</option>
</select>

I you want tool-tips on every option, you should consider developing a custom combo box that will implement that behavior (Using JQuery,HTML, CSS).

Orson
  • 14,981
  • 11
  • 56
  • 70
  • that was not my answer. I said that title works in option, but I want it to be displayed always – JPro Nov 30 '09 at 15:37
0

I worked using the title tag, but I was using this previously and this does not answer my question.

JPro
  • 6,292
  • 13
  • 57
  • 83
0

I am restricting the size of select, so I want the user be able to see long text that has been truncated in the title tag, as it gets disoplayed when the user hovers the mouse on the option

Just give it a width with help of a little CSS. In real webbrowsers the dropdown list width will automatically expand to the largest option when you open it. Only in a certain webbrowser developed by a team in Redmond the dropdown list width won't expand like that. It will hide large options which is indeed very hairpulling.

In that browser, you can use Javascript to control the width during the desired events. You can find a jQuery based example in this answer: Dropdownlist width in IE

Community
  • 1
  • 1
BalusC
  • 1,082,665
  • 372
  • 3,610
  • 3,555