Jump to content

jqurey scripting is not working in internet explorer


ashri
 Share

Recommended Posts

Hi all,i m makin a sign out drop down menu. i have sarched and over google and get a tutorial and apply it. this is fine with firefox, chrome, opera, and safari but not in internet explorer any version. here is my code <script type="application/javascript">$(document).ready(function() { $(".dropdown dt a").click( function(e) { $(".dropdown dd ul").toggle(); $(".dropdown dt a").toggleClass('active'); e.preventDefault(); } ); $(".dropdown dd ul li a").click(function() { $(".dropdown dd ul").hide(); }); $(document).bind('click', function(e) { var $clicked = $(e.target); if (! $clicked.parents().hasClass("dropdown")) { $(".dropdown dd ul").hide(); $(".dropdown dt a").removeClass('active'); } });});</script> <div class="user-section"><div class="user-account"><dl class="dropdown"> <dt><a href=""><span>dear adrian</span></a></dt> <dd> <ul> <li style="left: 25px;" class="signOutLi"><a href="">Sign Out</a></li> </ul> </dd></dl></div></div> .dropdown dd, .dropdown dt, .dropdown ul { margin:0px; padding:0px; z-index: 1; }.dropdown dd { position:relative; }.dropdown a {color:#fff;text-decoration:none;outline:none;}.dropdown a:hover { color:#D6D6D6;}.dropdown dt a:hover { color: #000000; }.dropdown dt a { border-radius: 3px; -moz-border-radius: 3px; display: block; padding-right: 20px; width: 120px; color:#000000;}.dropdown dt a:active,.dropdown dt a.active { border-radius: 4px 4px 0 0; -moz-border-radius: 4px 4px 0 0;}.dropdown dt a span { background: transparent url(../images/arrow.png) no-repeat scroll 113px 11px; cursor: pointer; display: block; padding: 4px; width: 160px; line-height: 18px; position: relative; top: -4px; *top: 10px; }.dropdown dt a.active span { background: transparent url(../images/arrow.png) no-repeat scroll 150px -12px;}.dropdown dd ul { border-radius: 0 0 8px 8px; -moz-border-radius: 0 0 4px 4px; background: #007b32 none repeat scroll 0 0; color: #fff; display: none; left: -25px; padding: 0 0 4px; position: absolute; top: 1px; width: auto; min-width: 145px; list-style:none;}.dropdown span.value { display:none; color: #FFF;}.dropdown dd ul li a { padding:5px; display:block; /*border-bottom: 1px solid #444;*/ color: #FFF;}.dropdown dd ul li a:hover { /*background-color: #444;*/}.dropdown img { border:none; vertical-align:middle; margin-right: 10px; float: left; }.signOutLi{ padding-top: 5px !important; padding-bottom: 0px !important; }.user-section { height: 80%; float: right; width: 160px; background-image: url(../images/user-icon2.png); background-repeat: no-repeat; background-position: left center; position:relative; left:25px;}.user-account { background-repeat: no-repeat; background-position: right center; font-size: 14px; color: #000; padding-left: 25px; /*line-height: 40px;*/ line-height: 15px;}anyone fix my problem and give an oportunity to thank!

Link to comment
Share on other sites

Start by testing with IE8 or IE9 and open the error console to look for error messages. You can press F12 to open developer tools and then find the script tag and the console area. There are links in my signature for more information about the developer tools in browsers.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...