An Example of this can be seen here: http://nces.ed.gov/datalab/quickstats/default.aspx Try clicking on one of the groups on the left and it should refresh the workspace with that group.
It works fine on all browsers in Windows 7 but fails in IE 7 and IE 8 on Vista.
I have this function:
function SelectGroup(gid,开发者_Go百科 glevel, gtext) {
alert('not running on my environment only in vista');
}
And this is what calls it:
<a href="javascript:SelectGroup('3','3','Beginning college students')" style='text-decoration:none;'><span id='span_draggable_3' onmouseover="NavOver('3','3')" onmouseout="NavOut('3','3')" style='cursor:pointer;'>Beginning college students</span></a></div>
Some general suggestions:
- Try to look if you have error messages, what do you mean by failed?
- Try first with FireFox, it has better development tools.
- IE8 has decent enough debugging tools, why wouldn't you use this?
- Use a library like Mootools and JQuery to abstract differences between the major browsers
- What about the old
alert
way of debugging things, have you tried it? - Try to narrow the problem the best you can, from my experience, this snipet is too big
edit: By telling in comments alerts don't run, it means you have an actual JS error somewhere and not a logic bug. Click on the error signal, bottom left of browser (yellow triangle with ! I believe), what is the message?
Edit: My friend, you have two other events I missed, What is the code of the onmouseover
event, this might trash your code.
AND you have a </span>
in the wrong place (no matching opening tag) this can also cause issues.
精彩评论