Note that there are some explanatory texts on larger screens.

plurals
  1. POJQuery not working properly in firefox and chrome
    primarykey
    data
    text
    <p>I am currently developing an ASP.NET webpage and I have run into the most irritating problem I have ever encountered. </p> <p>I have been researching this problem for the past three days, and cannot find anybody who has even had this problem, let alone any solutions.</p> <p>I have created a menu/submenu with HTML/CSS, and I am adding some kind of toggling effect to the submenu to make it either slide down or fade in (I've tried both, and both yield the same result).</p> <p>In Internet Explorer, it works great. I can hover over the menu, it'll slide down or fade in correctly, then when I move the mouse away it'll disappear.</p> <p>In Chrome/Firefox, I'm not so lucky. The submenu starts out hidden, then if I hover over it once, it will appear. If I move the mouse away, it instantly closes and then re-opens on its own. At this point, it's beyond return. If I hover over it, it disappears, and if I move the mouse away again, it'll re-appear. This will continue to happen until the page reloads.</p> <p>Here is the menu in HTML...</p> <pre><code>&lt;ul id="menu"&gt; &lt;li&gt;&lt;a href="Default.aspx"&gt;Home&lt;/a&gt;&lt;/li&gt; &lt;li&gt;&lt;a href="Services.aspx"&gt;Services&lt;/a&gt; &lt;ul id="submenu"&gt; &lt;li&gt;Custom CRM&lt;/li&gt; &lt;li&gt;Website Development&lt;/li&gt; &lt;/ul&gt; &lt;/li&gt; &lt;li&gt;&lt;a href="About.aspx"&gt;About&lt;/a&gt;&lt;/li&gt; &lt;li&gt;&lt;a href="Contact.aspx"&gt;Contact Us&lt;/a&gt;&lt;/li&gt; &lt;/ul&gt; </code></pre> <p>As for the CSS pertaining to this menu, this is it...</p> <pre><code>#menu { padding:0; text-align: center; margin: 0; width: 100%; } #menu li { height: 35px; float: left; list-style: none; width: 25%; font-size: larger; cursor: pointer; position: relative; } #menu li a { display: block; height: 35px; text-decoration: none; color: White; font-weight: bold; padding-top: 5px; } #menu li:hover { background-color: #4CC417; } #menu li:hover ul { display: block; } #menu ul { margin: 0; padding: 0; position: absolute; z-index: 999; top: 36px; width: 140%; display: none; list-style: none; left: 0; } #menu ul li { text-align: left; font-size: medium; width: auto; float: none; background-color: #387C44; color: White; font-weight: bold; padding-left: 5px; } #submenu ul { display: none; z-index: 999; } #submenu { display: none; } </code></pre> <p>And finally, here is the JQuery code I created for this...</p> <pre><code>&lt;script type="text/javascript"&gt; $(document).ready(function () { $("#menu ul").parent().hover(function () { $("#submenu").stop(true, true).fadeToggle("slow"); }); }); &lt;/script&gt; </code></pre> <p>Any help is greatly appreciated. Thank you!</p> <p>--Mark</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload