![]() |
|
|
Welcome to the { mindfrost82.com } forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact contact us. |
|
|||||||
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
|
|||
|
onmouseover on option does not work
Hi,
This is my first post in this newsgroup so I am hoping I am posting on the right thread. My question is that I have the following HTML code: function displayToolTip() { document.getElementById("Selection").options[document.getElementById("Selection").options.selec tedIndex].title = "Testing"; } <select id="selection"> <option onmouseover="javascript:displayToolTip();">1</option> <option onmouseover="javascript:displayToolTip();">2</option> </select> This works on FireFox but not on IE7. I have searched the net and a number of people encounter such similar problem and reported that this is IE bug. Is that right? |
|
|||
|
RE: onmouseover on option does not work
A bug in IE? Surely not!
The first thing I'd to recommend to you is to try the MSDN forums or even a place like CodeGuru in preference to this particular list. Actually I encounter problems just *viewing* this site with IE as it is today. Microsoft's own OS, browser, and site. Gives you an indication what you're up against. I remember a little JS (back in IE6 days) and would like to help if I can. What does IE actually do? The code looks exceedingly straightforward, at least out of context. If the answer is 'nothing' I'd make sure you've added your site to your trusted zone and try again. You might find this is a security 'feature' - I think they've tightened up the whole 'document.getEverything.andHackMe' scenario since I used to do this sort of work. I'd also try doing something else from the onmouseover just to be sure it's firing, if you haven't already done that. That and testing to see if you can fire the event another way and get the desired effect of changing the selector option. Stay hopeful. The good thing I remember about IE6 was for every bug there was probably another you could exploit to work around it. :-) I remember doing some really crazy things with invisible frames to make them 'talk', but I couldn't hope to remember all the specifics and no doubt it wouldn't work these days. Sorry I can't be more helpful off the bat, but again I'd need to know what IE actually does with this code (can you post a complete 'working' example?). For a *really* good laugh (in your spare time), hopefully this one still works: (all on one line) <tr><td>directly</td></tr><tr height=1><td></td></tr><tr><td>above</td></tr> gives you a TR of height 1 <tr><td>totally</td></tr> <tr><td height=1></td></tr> <tr><td>broken</td></tr> gives you the emtpy TR at current font height. I could have killed someone when my whole site design was thrown out by that (it took a couple of days to fix and a couple more to understand why it kept breaking) , and if you haven't considered possibilities like this, you should probably start. :-D Aaron. "Mike" wrote: > Hi, > > This is my first post in this newsgroup so I am hoping I am posting on the > right thread. > > My question is that I have the following HTML code: > > function displayToolTip() > { > > document.getElementById("Selection").options[document.getElementById("Selection").options.selec tedIndex].title = "Testing"; > } > > <select id="selection"> > <option onmouseover="javascript:displayToolTip();">1</option> > <option onmouseover="javascript:displayToolTip();">2</option> > </select> > > This works on FireFox but not on IE7. I have searched the net and a number > of people encounter such similar problem and reported that this is IE bug. Is > that right? > > |
![]() |
|
| Thread Tools | Search this Thread |
| Display Modes | |
|
|