<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>ADxMenu on A&#43; programming moments</title>
    <link>https://aplus.rs/categories/adxmenu/</link>
    <description>Recent content in ADxMenu on A&#43; programming moments</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-us</language>
    <lastBuildDate>Sun, 18 Jan 2009 13:53:17 +0000</lastBuildDate>
    
	<atom:link href="https://aplus.rs/categories/adxmenu/index.xml" rel="self" type="application/rss+xml" />
    
    
    <item>
      <title>IE8 beta2 considered harmful</title>
      <link>https://aplus.rs/2009/ie8-beta2-considered-harmful/</link>
      <pubDate>Sun, 18 Jan 2009 13:53:17 +0000</pubDate>
      
      <guid>https://aplus.rs/2009/ie8-beta2-considered-harmful/</guid>
      <description>&lt;p&gt;I was notified that ADxMenu does not work in IE8 beta2. Apparently, it suffers from &lt;a href=&#34;http://www.brunildo.org/test/IE8beta2-CSS-bugs.html&#34;&gt;several CSS bugs&lt;/a&gt; that are triggered by my menu. Nothing to actually do about it, only hope that Microsoft developers will fix these soon.&lt;/p&gt;
&lt;p&gt;These bugs are introduced in the beta2, as the menu was working fine with beta1. New IE engine&amp;rsquo;s growing hickups, I guess.&lt;/p&gt;
&lt;p&gt;Update: Microsoft developers fixed this in IE8. My menu is working just fine there.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Small update for ADxMenu</title>
      <link>https://aplus.rs/2008/small-update-for-adxmenu/</link>
      <pubDate>Wed, 28 May 2008 10:51:48 +0000</pubDate>
      
      <guid>https://aplus.rs/2008/small-update-for-adxmenu/</guid>
      <description>&lt;p&gt;I implemented the latest version of the &lt;a href=&#34;https://aplus.rs/adxmenu/&#34;&gt;ADxMenu&lt;/a&gt; script in company&amp;rsquo;s web sites and found a problem. I use the full version of &lt;a href=&#34;http://www.cherny.com/webdev/27/domloaded-updated-again&#34;&gt;DOMLoaded.js&lt;/a&gt; script for those websites and ADxMenu.js internally uses just the IE part of the same script.&lt;/p&gt;
&lt;p&gt;When loaded both, they collide and ADxMenu&amp;rsquo;s &lt;code&gt;Setup()&lt;/code&gt; is never called.&lt;/p&gt;
&lt;p&gt;I have recoded this so that my script is now completely independent of anything else on the page. Everything is up, so you can re-download the script and use it.&lt;/p&gt;
&lt;p&gt;p.s. This is 300th post on my blog. I find it nice that it&amp;rsquo;s ADxMenu themed.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>ADxMenu accessibility update for IE6</title>
      <link>https://aplus.rs/2008/adxmenu-accessibility-update-for-ie6/</link>
      <pubDate>Thu, 17 Apr 2008 22:58:03 +0000</pubDate>
      
      <guid>https://aplus.rs/2008/adxmenu-accessibility-update-for-ie6/</guid>
      <description>&lt;p&gt;Aaron J. Young from &lt;a href=&#34;http://www.ouhsc.edu/&#34;&gt;OUHSC&lt;/a&gt; recently wrote with question:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I was wondering how one might be able to modify your ADxMenu so that if someone has IE6 and Javascript disabled it would simply show the entire tree menu.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I prefer to add actual links to main menu items and have sub navigation shown on each of those pages. However, this is reasonable request that improves the accessibility of the menu, thus I looked into possible solution. I wanted to avoid changing HTML for the menu and I think I came up with good solution &amp;ndash; keeping in mind that this will be seen and executed only by IE6.&lt;/p&gt;
&lt;p&gt;The main &lt;a href=&#34;https://aplus.rs/adxmenu/examples/&#34;&gt;four menu examples&lt;/a&gt; are updated, as well as downloadable archive. There&amp;rsquo;s also &lt;a href=&#34;https://aplus.rs/adxmenu/examples/ie6-double-style/&#34;&gt;one new example&lt;/a&gt; that shows how you can create two different styles, one when Javascript is enabled and one when it&amp;rsquo;s disabled.&lt;/p&gt;
&lt;h3 id=&#34;how-it-works&#34;&gt;How it works&lt;/h3&gt;
&lt;p&gt;Part of the CSS that initially hides submenus is this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;visibility&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;hidden&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;absolute&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Thus, for IE6, that had to be removed and activated only if Javascript works. Which means that now, inside the conditional comments I have this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;visibility&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;visible&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;static&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;and the new version of the &lt;a href=&#34;https://aplus.rs/adxmenu/examples/code/ADxMenu.js&#34;&gt;ADxMenu.js&lt;/a&gt; contains this bit (it&amp;rsquo;s all one line, broken here to be more understandable):&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nb&#34;&gt;document&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;write&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s1&#34;&gt;&amp;#39;&amp;lt;style type=&amp;#34;text/css&amp;#34; media=&amp;#34;all&amp;#34;&amp;gt;&amp;#39;&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;+&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;s1&#34;&gt;&amp;#39;.menu ul {visibility:hidden; position:absolute;}&amp;#39;&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;+&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;s1&#34;&gt;&amp;#39;&amp;lt;/style&amp;gt;&amp;#39;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;);&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I avoid &lt;code&gt;document.write&lt;/code&gt; in my code as much as possible &amp;ndash; the correct place to do this would be in the &lt;code&gt;Setup&lt;/code&gt; method, for each menu found on the page. However, that means that menu will be visible even with Javascript ON, for that brief moment or two until script kicks in. Since this is custom made only for IE6, shown code line is better solution.&lt;/p&gt;
&lt;h3 id=&#34;a-step-further-different-styles&#34;&gt;A step further: different styles&lt;/h3&gt;
&lt;p&gt;I have a hard time visualizing menu that would look acceptable with Javascript on/off and to use the same styles. Even with simple and short menus, I don&amp;rsquo;t think it would look fine in most cases.&lt;/p&gt;
&lt;p&gt;Given that, the script now has this line:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;aTmp&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;i&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;].&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;aTmp&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;i&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;].&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;replace&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;adxie&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;);&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;where &lt;code&gt;aTmp&lt;/code&gt; is an array of menu elements that have the &lt;code&gt;adxm&lt;/code&gt; class. This requires you to add one more class to the main list, like this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-html&#34; data-lang=&#34;html&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;class&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;#34;adxm menu adxie&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Using this class, you can then create IE6-only styles for the case when Javascript is OFF and leave the usual menu styles for the case when Javascript is ON. For this to work, make sure you write the JS-ON styles first, then the JS-OFF below them. The &lt;a href=&#34;https://aplus.rs/adxmenu/examples/ie6-double-style/&#34;&gt;new example&lt;/a&gt; shows just that.&lt;/p&gt;
&lt;p&gt;If changing the menu HTML is not an option &amp;ndash; like too many existing pages to be updated in reasonable time &amp;ndash; then you can do the reverse thing. Comment-out the previous line in the script and uncomment this one:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;aTmp&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;i&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;].&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;+=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34; adxie&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Thus, you can use your existing &lt;code&gt;menu&lt;/code&gt; class to style the JS-OFF solution and &lt;code&gt;adxie&lt;/code&gt; to style the drop-down case (JS-ON). First solution is noticeably easier to do and maintain, so go with it if possible.&lt;/p&gt;
&lt;p&gt;I took this opportunity to rewrite the script a bit, nothing really important. There you go, 1st update of the menu since January last year. :)&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ADxMenu v4.10</title>
      <link>https://aplus.rs/2007/adxmenu-v410/</link>
      <pubDate>Fri, 05 Jan 2007 22:31:58 +0000</pubDate>
      
      <guid>https://aplus.rs/2007/adxmenu-v410/</guid>
      <description>&lt;p&gt;After finishing this update, I had yet another moment of how in the hell I didn&amp;rsquo;t figured this before. You know the feeling - you struggle with certain code for weeks or months, and then after you surrender to the reality and code the &amp;ldquo;just work, bitch&amp;rdquo; parts, you realize the simple solution was waiting just around the corner of your mind.&lt;/p&gt;
&lt;p&gt;With several simple lines in the script, I can now use &lt;em&gt;much&lt;/em&gt; simpler IE6-only CSS. Menus now work with any number of levels, without the need to update the ugly &lt;code&gt;.menu .adxmhover ul, .menu .adxmhover .adxmhover ul, .menu .adxmhover .adxmhover .adxmhover ul....&lt;/code&gt; rules.&lt;/p&gt;
&lt;p&gt;Even better, you now have - in IE6 - direct (not simulated) replacements for the following selectors:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;li:hover&lt;/code&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;li:hover&amp;gt;a&lt;/code&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;li:hover&amp;gt;ul&lt;/code&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;script-changes&#34;&gt;Script changes&lt;/h3&gt;
&lt;p&gt;It&amp;rsquo;s so simple.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m using script for IE6, in which I&amp;rsquo;m already using this replication of &lt;code&gt;li:hover&lt;/code&gt;:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;onmouseenter&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;+=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34; adxmhover&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;...&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;which is then used in IE6-only styles as &lt;code&gt;li.adxmhover&lt;/code&gt;. Well, why not add more replacements? With this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;UL&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;getElementsByTagName&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;ul&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)[&lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;];&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;A&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;getElementsByTagName&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;a&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)[&lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;];&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;onmouseenter&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;...&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;UL&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;+=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34; adxmhoverUL&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;A&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;+=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34; adxmhoverA&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I can replace &lt;code&gt;li:hover&amp;gt;a&lt;/code&gt; with &lt;code&gt;a.adxmhoverA&lt;/code&gt; and &lt;code&gt;li:hover&amp;gt;ul&lt;/code&gt; with &lt;code&gt;ul.adxmhoverUL&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;No need to simulate anything, simply repeat the style rules in IE6-only part using replacement class selectors and&amp;hellip;that&amp;rsquo;s it. You can of course update the script and add replacements for other advanced selectors, but this is basically all that I ever needed in menu styling.&lt;/p&gt;
&lt;h3 id=&#34;css-changes&#34;&gt;CSS changes&lt;/h3&gt;
&lt;p&gt;The whole thing started with IE7 problems with &lt;code&gt;display&lt;/code&gt; property. I recoded CSS to use &lt;code&gt;visibility&lt;/code&gt; instead, but then Safari went scrollbars-crazy - it was due to this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt; &lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;static&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt; &lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;relative&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I then tried this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt; &lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;kc&#34;&gt;relative&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt; &lt;span class=&#34;k&#34;&gt;z-index&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;5&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt; &lt;span class=&#34;k&#34;&gt;z-index&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;10000&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;but IE7 ignored &lt;code&gt;z-index&lt;/code&gt; change. Now really on the end of my nerves, I coded horrible positioning trickery (horizontal bottom-top variant was the worst) to minimize all problems. Luckily, good man David &lt;a href=&#34;https://aplus.rs/css/ie7-bug-will-not-render-z-index-change-on-lihover/#comment-16755&#34;&gt;pin-pointed&lt;/a&gt; solution for IE7&amp;rsquo;s &lt;code&gt;li:hover&lt;/code&gt; issue.&lt;/p&gt;
&lt;p&gt;At this point, I was so happy :) that it&amp;rsquo;s no wonder ideas sparked all over the place and dust was off the mind corner where replacement class selectors peacefully nap.&lt;/p&gt;
&lt;h3 id=&#34;wrap-up&#34;&gt;Wrap up&lt;/h3&gt;
&lt;p&gt;&lt;a href=&#34;https://aplus.rs/adxmenu/instructions/&#34;&gt;Instructions&lt;/a&gt; page is updated, &lt;a href=&#34;https://aplus.rs/adxmenu/trouble/&#34;&gt;Troubleshooting&lt;/a&gt; is a lot shorter and 4 basic &lt;a href=&#34;https://aplus.rs/adxmenu/examples/&#34;&gt;examples&lt;/a&gt; are updated to latest code.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ADxMenu v4 - flyout (drop-down) menu</title>
      <link>https://aplus.rs/2006/adxmenu-v4-flyout-drop-down-menu/</link>
      <pubDate>Tue, 12 Dec 2006 00:01:00 +0000</pubDate>
      
      <guid>https://aplus.rs/2006/adxmenu-v4-flyout-drop-down-menu/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://aplus.rs/adxmenu/&#34;&gt;v4 is online&lt;/a&gt; for some time now and people have already used it. This version is the result of the months and months of experience implementing previous version on all kinds of web sites.&lt;/p&gt;
&lt;p&gt;I have changed the basic CSS, but just a bit, mainly simplified it. Important changes from the v3 are:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Completely clean HTML inside the menu - there are no classes, no IDs&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Behavior component (.htc) is not used anymore - it uses plain Javascript&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Instant execution of the IE script, thus making the menu usable even before the entire page content is downloaded&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;WCH is not part of the script, but it uses it if it&amp;rsquo;s available You must include WCH.js before the ADxMenu.js for this to work&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;code&gt;li:hover&lt;/code&gt; is not simulated automatically, you must write the CSS yourself, using &lt;code&gt;adxmhover&lt;/code&gt; class&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Submenu opening now gives you certain degree of freedom - they will not disappear if you move the mouse slightly off the submenu&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Much, much quicker in IE than v3&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;The most important improvement is certainly the last one. I &lt;a href=&#34;https://aplus.rs/adxmenudev/end-of-the-road/&#34;&gt;wrote&lt;/a&gt; 1.5 years ago about the speed issues of the ADxMenu v3. The good thing about the &lt;a href=&#34;https://aplus.rs/adxmenudev/the-ultimate-drop-menu/&#34;&gt;.htc-based version&lt;/a&gt; is great CSS ease of use; bad thing: only usable for small menus. I posted a quick JS-based fix back then, but it was applicable only in controlled cases. For longer menus it was simply not good enough, and usability is what counts in the end. This version is speed beast.&lt;/p&gt;
&lt;p&gt;This new version is simplification effort. I have gave up on the &amp;ldquo;ultimate&amp;rdquo;, &amp;ldquo;enterprise&amp;rdquo; and similar adjectives. From the implementation questions I receive on the daily basis, I realized that it&amp;rsquo;s not really possible to make it work in like 1-2-3, for all people and for all cases. Thus, the clean-up.&lt;/p&gt;
&lt;h3 id=&#34;the-cleanest-html-you-can-imagine&#34;&gt;The cleanest HTML you can imagine&lt;/h3&gt;
&lt;p&gt;The basic CSS and the script require no IDs and no classes inside the menu body. The only thing required is that you put &lt;code&gt;class=&amp;quot;adxm&amp;quot;&lt;/code&gt; on the main ul element and that&amp;rsquo;s it. In browsers supporting &lt;code&gt;li:hover&lt;/code&gt; and &lt;code&gt;li&amp;gt;ul&lt;/code&gt; selectors, that is all that&amp;rsquo;s needed.&lt;/p&gt;
&lt;p&gt;Obviously, if you have more than one menu on the page, then you would use something like: &lt;code&gt;class=&amp;quot;menutop adxm&amp;quot;&lt;/code&gt; and &lt;code&gt;class=&amp;quot;sidemenu adxm&amp;quot;&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Any other classes and IDs you add can be used to implement complicated designs, icons or whatever.&lt;/p&gt;
&lt;h3 id=&#34;javascript-for-ie6&#34;&gt;Javascript for IE6&lt;/h3&gt;
&lt;p&gt;If you look at the source code of the &lt;a href=&#34;https://aplus.rs/adxmenu/examples/&#34;&gt;examples&lt;/a&gt;, you will see how easy is to add it:&lt;/p&gt;
&lt;p&gt;[code]&lt;/p&gt;
&lt;p&gt;[/code]&lt;/p&gt;
&lt;p&gt;What does it do? It looks for all &lt;code&gt;ul&lt;/code&gt; elements with the class of &lt;code&gt;adxm&lt;/code&gt;. Then for each of them fetches all &lt;code&gt;li&lt;/code&gt; elements and looks for those that have nested lists. It attaches the following two event handlers on matched &lt;code&gt;li&lt;/code&gt; elements:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;// li:hover
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;onmouseenter&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;style&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;position&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;relative&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;+=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34; adxmhover&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;//	li:blur
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c1&#34;&gt;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;onmouseleave&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;style&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;position&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;static&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;replace&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;sr&#34;&gt;/adxmhover/&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;);&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The newly created class can then be used to replicate the &lt;code&gt;:hover&lt;/code&gt; and the child selector, in the following manner:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;adxmhover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;adxmhover&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;adxmhover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;visibility&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;visible&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;adxmhover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;adxmhover&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nc&#34;&gt;adxmhover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;visibility&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;hidden&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Easy peasy.&lt;/p&gt;
&lt;p&gt;Why the position setting? It&amp;rsquo;s a well known fact that IE6 has faulty implementation of positioning context stacking. That leads to huge problems, one of which is illustrated in the &lt;a href=&#34;https://aplus.rs/css/ie6-posctxstacking/&#34;&gt;short example&lt;/a&gt; I mocked up, where that line is deleted from the script. Using this line, only the currently hovered item has the &lt;code&gt;position&lt;/code&gt; set to &lt;code&gt;relative&lt;/code&gt; and thus there are no problems with context stacking.&lt;/p&gt;
&lt;h3 id=&#34;speed-daemon&#34;&gt;Speed daemon&lt;/h3&gt;
&lt;p&gt;Consequence of this positioning trickery is that IE is constantly re-rendering the page, since &lt;code&gt;position:relative&lt;/code&gt; changes the position of the nested submenu. This is the major source of the speed issues in IE, when mouse is quickly moved up/down on the large menu. Take a look at the example using &lt;a href=&#34;https://aplus.rs/adxmenu/htc-perf/&#34;&gt;old .htc-based code&lt;/a&gt;, in IE (you can witness the freeze at the start of the page while .htc works). Hover any item in left-hand menu, for instance soccer or horse racing. Then move the mouse up and down - IE will visibly lag behind your movement. When looked in Firefox, all is breeze, as they implement context stacking properly and do not require this position trickery.&lt;/p&gt;
&lt;p&gt;And now look at the same page design, same menus, but &lt;a href=&#34;https://aplus.rs/adxmenu/v4-perf/&#34;&gt;using v4&lt;/a&gt;. Repeating the test from above, you can see that everything is breeze in IE too.&lt;/p&gt;
&lt;h3 id=&#34;usability&#34;&gt;Usability&lt;/h3&gt;
&lt;p&gt;The advantage no.3 from the list at the post start. &lt;em&gt;Huge usability improvement&lt;/em&gt;, especially on large, heavy pages. Having the script executing practically immediately after .html page downloads, without the wait on flash files, videos, images - this is my second favourite feature of the new version. I have prepared the example that &lt;a href=&#34;https://aplus.rs/adxmenu/examples/domonload/&#34;&gt;demonstrates this&lt;/a&gt; - menu is working in IE before the image has finished downloading. You people with those damn fast internet links might not even notice this, if the image downloads in few secs. We, ones with cheaper tickets, have no such &amp;ldquo;problem&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;All thanks goes to &lt;a href=&#34;http://dean.edwards.name/weblog/2006/06/again/&#34;&gt;Dean Edwards&lt;/a&gt;, &lt;a href=&#34;http://www.outofhanwell.com/blog/index.php?title=using_window_onload_over_https&#34;&gt;Matthias Miller&lt;/a&gt; and &lt;a href=&#34;http://ejohn.org/&#34;&gt;John Resig&lt;/a&gt;, plus &lt;a href=&#34;http://www.cherny.com/webdev/27/domloaded-updated-again&#34;&gt;Rob Cherny&lt;/a&gt; for a lovely script I use.&lt;/p&gt;
&lt;h3 id=&#34;onmouseenter-onmouseleave&#34;&gt;Onmouseenter, onmouseleave&lt;/h3&gt;
&lt;p&gt;These two event handlers are IE-specific. Very useful little devils. I have used them on the latest variants of the v3, but I mention them here mainly to illustrate how much better they are, for this case, then &lt;code&gt;onmouseover&lt;/code&gt; and &lt;code&gt;onmouseout&lt;/code&gt;. &lt;a href=&#34;https://aplus.rs/adxmenu/iemouseeventhdltest/&#34;&gt;The example&lt;/a&gt; (open it in IE) open small window in the top right corner and populates it each time any of these 4 handlers are called. Move your mouse around the menu and be ready to puke at the number of times onmouseover/out are called.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/v4/mousevents.png&#34; alt=&#34;Mouse events&#34;&gt;&lt;/p&gt;
&lt;p&gt;This nicely influence the speed, in all the good ways.&lt;/p&gt;
&lt;h3 id=&#34;a-degree-of-freedom&#34;&gt;A degree of freedom&lt;/h3&gt;
&lt;p&gt;Credits for this goes to John Gallant of the PiE fame. In his &lt;a href=&#34;http://www.positioniseverything.net/css-dropdowns.html&#34;&gt;flyout menu example&lt;/a&gt;, he implemented a fabulous little trick, shown on the following screenshot.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/v4/safearea.png&#34; alt=&#34;Mouse events&#34;&gt;&lt;/p&gt;
&lt;p&gt;He placed each of the nested lists inside a div, which was slightly larger than the list itself, by adding &lt;code&gt;padding&lt;/code&gt; to it. The whole div is then negatively margined for the same value used for padding. Since div is transparent, you don&amp;rsquo;t see this, but you notice that submenus does not disappear when your hand slips a bit off the submenu. Not 100% slip-proof, but very close.&lt;/p&gt;
&lt;p&gt;My examples are so simple, that I don&amp;rsquo;t even need the extra element and use the nested &lt;code&gt;ul&lt;/code&gt; elements for that, while all the styles are applied on the &lt;code&gt;li&lt;/code&gt; elements.&lt;/p&gt;
&lt;h3 id=&#34;your-turn&#34;&gt;Your turn&lt;/h3&gt;
&lt;p&gt;There you go. Checkout my simple &lt;a href=&#34;https://aplus.rs/adxmenu/examples/&#34;&gt;examples&lt;/a&gt;, fly through the &lt;a href=&#34;https://aplus.rs/adxmenu/instructions/&#34;&gt;instructions&lt;/a&gt; and don&amp;rsquo;t forget to check the &lt;a href=&#34;https://aplus.rs/adxmenu/trouble/&#34;&gt;Troubleshooting&lt;/a&gt; section if you have problems.&lt;/p&gt;
&lt;p&gt;And implement, implement, implement&amp;hellip;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>IE7 is ADxMenu compatible</title>
      <link>https://aplus.rs/2006/ie7-is-adxmenu-compatible/</link>
      <pubDate>Tue, 21 Mar 2006 17:47:54 +0000</pubDate>
      
      <guid>https://aplus.rs/2006/ie7-is-adxmenu-compatible/</guid>
      <description>&lt;p&gt;It really is.&lt;/p&gt;
&lt;p&gt;I just tried latest IE7 beta 2 (so called MIX06 release) and examples work as expected (did not fully tested though, just the basics).&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Ooooh, yes!</title>
      <link>https://aplus.rs/2005/ooooh-yes/</link>
      <pubDate>Sat, 30 Jul 2005 23:37:12 +0000</pubDate>
      
      <guid>https://aplus.rs/2005/ooooh-yes/</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;# CSS 2.1 Selector support (child, adjacent, attribute, first-child etc.)&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Thus, from &lt;a href=&#34;http://blogs.msdn.com/ie/archive/2005/07/29/445242.aspx&#34;&gt;IE7 beta 2&lt;/a&gt; (maybe) and IE 7 final (for sure) &lt;a href=&#34;https://aplus.rs/adxmenu/examples/&#34;&gt;ADxMenu&lt;/a&gt; will work without helper scripts (at least in the standard version). The long walk towards &lt;em&gt;IE6 1%&lt;/em&gt; records will then begin.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>End of the road?</title>
      <link>https://aplus.rs/2005/end-of-the-road/</link>
      <pubDate>Sat, 07 May 2005 12:14:12 +0000</pubDate>
      
      <guid>https://aplus.rs/2005/end-of-the-road/</guid>
      <description>&lt;p&gt;My long-time readers may remember that, back in the early days, ADxMenu had two versions. One that used .htc file and only one set of styles and the other that used only javascript but two sets of styles. The reason was that .htc version at that time used original Peter Nederlof&amp;rsquo;s csshover.htc which went through entire document looking for elements to apply &lt;code&gt;:hover&lt;/code&gt; trickery and thus had far from good performance on very long pages.&lt;/p&gt;
&lt;p&gt;Things changed when I recoded it to work only with menu elements and ADxMenu 3 utilized it to its fullest potential.&lt;/p&gt;
&lt;p&gt;However, performance issues are not defeated yet. In the last project I&amp;rsquo;m working on, I have three menus on one page and two of them are very large. The page itself also features a great deal of various positioning, using both floats and pos/abs position. Accompanied with these three menus, this brings IE to its knees - it takes him 4-5s on P4-2.8GHz with half-gig of RAM to render that page and execute the .htc. 90% of that freeze time goes on .htc processing.&lt;/p&gt;
&lt;p&gt;But not only that. Since my css applies &lt;code&gt;position:relative&lt;/code&gt; on &lt;code&gt;li:hover&lt;/code&gt; and thus does the actual positioning in that moment, re-rendering of the page takes some time and going from one menu option to another has a very noticeable lag. Last time I have seen such behavior was with Netscape Navigator 4. Sigh&amp;hellip;&lt;/p&gt;
&lt;p&gt;I created &lt;a href=&#34;https://aplus.rs/adxmenu/htc-perf/&#34;&gt;test page&lt;/a&gt; with completely stripped-down page leaving just menus where you can still notice the lag, both on page load and when traversing the left-hand menus - for a fraction of second you can see the busy cursor popping up. The numeric value in the middle is how long it takes IE to complete the .htc processing. And than imagine how this looks like when Sports menu has 3x more items (as is the case on production environment).&lt;/p&gt;
&lt;p&gt;I spent entire afternoon, measuring where is all this time spent. It appears that each &lt;code&gt;_currentStyle_.addRule&lt;/code&gt; call takes about 50-60ms, and some 1s is lost on function calls overhead. I don&amp;rsquo;t see a solution with .htc anymore as it seems that IE&amp;rsquo;s Trident engine has its limits. Pages that use heavy positioning are simply not what IE can handle well. I could be wrong, but the more positioning I add, the less responsive it becomes.&lt;/p&gt;
&lt;p&gt;It is time for different IE strategy. I could easily end up dumping .htc all together and go back to Javascript and delayed initialization. This could prove to be a &lt;a href=&#34;https://aplus.rs/adxmenu/intro/#troubleshoot&#34;&gt;good thing after all&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;For those interested, I resolved the perfomance problem by completly removing .htc, rewriting the design rules so that none of them used &lt;code&gt;li:hover&lt;/code&gt; and execute this script on &lt;code&gt;window.onload&lt;/code&gt;:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;xGetElementsByClassName&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;adxm&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;nb&#34;&gt;document&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;ul&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;oUL&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;nx&#34;&gt;xGetElementsByClassName&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;submenu&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;oUL&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;li&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;		&lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;onmouseover&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;			&lt;span class=&#34;k&#34;&gt;if&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;!&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;UL&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;				&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;UL&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;getElementsByTagName&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;ul&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)[&lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;];&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;			&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;UL&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;style&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;visibility&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;visible&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;		&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;		&lt;span class=&#34;nx&#34;&gt;oLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;onmouseout&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;			&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;UL&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;style&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;visibility&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;hidden&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;		&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;);&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;);&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;And this works near instant.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Small update</title>
      <link>https://aplus.rs/2005/small-update/</link>
      <pubDate>Mon, 21 Feb 2005 21:58:29 +0000</pubDate>
      
      <guid>https://aplus.rs/2005/small-update/</guid>
      <description>&lt;p&gt;I have updated the &lt;a href=&#34;https://aplus.rs/adxmenu/examples/&#34;&gt;example listing&lt;/a&gt; with an example of menu with &lt;a href=&#34;https://aplus.rs/adxmenu/examples/netymology-hs/&#34;&gt;horizontal submenus&lt;/a&gt;. This was asked several times and I got time to do it last week while staying at home, recovering from the flu (or some similar thing).&lt;/p&gt;
&lt;p&gt;During development, I accidentally found the problem in IE, with .htc. If you have some &lt;code&gt;:hover&lt;/code&gt; rule which is empty, IE will throw &lt;em&gt;&amp;ldquo;invalid pointer&amp;rdquo;&lt;/em&gt; error. I updated all .htc files to fix this - they are all now in .21 version.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Porsche.GB with new (web) engine</title>
      <link>https://aplus.rs/2004/porschegb-with-new-web-engine/</link>
      <pubDate>Mon, 29 Nov 2004 17:45:24 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/porschegb-with-new-web-engine/</guid>
      <description>&lt;p&gt;I was surfing the web on Friday looking for examples of good drop menus I could replicate using &lt;a href=&#34;https://aplus.rs/adxmenu/intro/&#34;&gt;ADxMenu&lt;/a&gt;, to fill-up the examples sections. I was fairly positive I could find lots of such on automotive sites, as for some reason they tend to have them in packs.&lt;/p&gt;
&lt;p&gt;After few attempts, I found a &lt;a href=&#34;http://www2.uk.porsche.com/english/gbr/home.htm&#34;&gt;web site&lt;/a&gt; that immediately presented itself as perfect example for the use of ADxMenu, and also for CSS-based design.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://aplus.rs/deliver/porsche/new/&#34;&gt;&lt;img src=&#34;https://aplus.rs/images/deliver/porsche.png&#34; alt=&#34;Porsche GB&#34;&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I present you recoded &lt;a href=&#34;https://aplus.rs/deliver/porsche/new/&#34;&gt;Porsche GB&lt;/a&gt;, using no tables and full power of ADxMenu.&lt;/p&gt;
&lt;h4 id=&#34;analysis&#34;&gt;Analysis&lt;/h4&gt;
&lt;p&gt;I started from the &lt;a href=&#34;https://aplus.rs/deliver/porsche/old/&#34;&gt;snapshot&lt;/a&gt; I took in Firefox on Friday, Nov 26th. One look at the web code and you can clearly see the trade-marks of last century designs:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;dozens of &lt;code&gt;trans.gif&lt;/code&gt; (usually called &lt;code&gt;spacer.gif&lt;/code&gt;) images&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;extensive use of inline scripts and styles (even with several external files)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;lots of nested tables&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The actual snapshot I took also had &lt;code&gt;display:none&lt;/code&gt; hard coded on the large banner in the middle and on the second banner (composite brakes) below it. This has lead to design fall-out, as images for the upper row of navigation were misplaced, and the popup menus for the lower nav row completely covered the images (can still be seen on the live site, at the moment of posting this entry).&lt;/p&gt;
&lt;p&gt;The page foot-print is &lt;strong&gt;54kB&lt;/strong&gt;, with additional &lt;strong&gt;62kB&lt;/strong&gt; of scripts, spread over 7 files.&lt;/p&gt;
&lt;h4 id=&#34;re-coding&#34;&gt;Re-coding&lt;/h4&gt;
&lt;p&gt;Removal of unnecessary markup and creation of large navigation lists took me roughly 1.5h - I hate copy &amp;amp; paste. Coding appropriate markup for the design took less than an hour (I went for XHTML 1.0 Strict). Which left me with CSS and imagery.&lt;/p&gt;
&lt;p&gt;On/off states for navigation images are merged into one image and with CSS development and clean-up it lasted about 3-4h.&lt;/p&gt;
&lt;p&gt;End result was tested in a variety of modern browsers. Firefox, IE6 and Opera 7.52 display as I intended it (with small but acceptable hick-up in Opera). Safari, Omniweb and other WebCore co. have no support for &lt;code&gt;min-height&lt;/code&gt; (which I used for navigation lists). Thus I was forced to compromise on bottom navigation. Instead of having 75-80px for &lt;code&gt;bottom&lt;/code&gt; position of the submenu, I used 50px so you can actually move the mouse over to submenu. In Opera 6 it looks just as in Safari (&lt;em&gt;sans&lt;/em&gt; the submenus, of course), and almost perfect in IE5/Mac - if you know why is that content block moved to the left, please tell.&lt;/p&gt;
&lt;p&gt;All in all, it was a nice exercise for a lovely grid design, and a wonderful example of menu use.&lt;/p&gt;
&lt;p&gt;The page is now &lt;strong&gt;8.4kB&lt;/strong&gt;, which means that &lt;strong&gt;savings are over 80%&lt;/strong&gt;. It also has several .css files which would be merged into two files if I were doing this for production site + .htc file for IE - all combined it makes &lt;strong&gt;13kB&lt;/strong&gt;, giving another &lt;strong&gt;80% saving&lt;/strong&gt; on external files. Since I have merged navigation images I have very important savings on HTTP requests - about 2x down from the original number.&lt;/p&gt;
&lt;p&gt;Benefits are more than obvious.&lt;/p&gt;
&lt;h4 id=&#34;last-thoughts&#34;&gt;Last thoughts&lt;/h4&gt;
&lt;p&gt;For this design, I think that images in the navigation are an overkill. The page is graphic heavy as it is, and I think that it looks better with just words. Original site uses animated GIFs for the text - I used text for better usability, with few compromises to account different text size. I also fixed the size of the header area to match the width of the grid.&lt;/p&gt;
&lt;p&gt;The grid size is 783px which is 13px above what I consider the safe limit. Hence, in 800x600, horizontal scrollbar appear, so this should be fixed as well.&lt;/p&gt;
&lt;p&gt;If you remove some of the banners in my recoded page, nothing will break - elements will simply reflow. In current design, this is not the case.&lt;/p&gt;
&lt;p&gt;Both ADxMenu and modern web design technologies simply &lt;em&gt;shine&lt;/em&gt; in this real-world example. Porsche is not the only design with lots of menus and I can only hope that 2005 will be the year when nested tables and unnecessary use of Javascript will start to disapper significantly.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>The ultimate drop menu</title>
      <link>https://aplus.rs/2004/the-ultimate-drop-menu/</link>
      <pubDate>Fri, 26 Nov 2004 16:10:16 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/the-ultimate-drop-menu/</guid>
      <description>&lt;p&gt;&lt;a href=&#34;https://aplus.rs/adxmenu/intro/&#34;&gt;ADxMenu&lt;/a&gt; - multilevel menu built from nested HTML lists - is my pride and joy. I began working on it last year, always implementing the good stuff I learned on the web standards road. In its current incarnation, I believe it&amp;rsquo;s best of the breed. There are other menus out there (using the very similar HTML base), but most of them can, at most, measure up to ADxMenu standard.&lt;/p&gt;
&lt;p&gt;With that said, I want to repeat what was my target from day 1. It&amp;rsquo;s valid, standard-compliant web sites. If you have an old-school web site with nested tables and no DOCTYPE - do not bother; you have other things to conquer first. On the other hand, if you are a CSS newbie/inter/pro - you are welcomed. You will need good CSS skills to create attractive menus though; I did my best to give you a &lt;a href=&#34;https://aplus.rs/adxmenu/intro/#instructions&#34;&gt;good starting point&lt;/a&gt;, for 4 different variants of the menu, but the final look is up to you.&lt;/p&gt;
&lt;p&gt;There are many old-school menus with large scripts and over-bloated markup. Those few that are good and light are not free. &lt;em&gt;ADxMenu3 is free&lt;/em&gt; to use on any kind of site, as long as you give &lt;a href=&#34;http://creativecommons.org/licenses/by-sa/2.0/&#34;&gt;proper attribution&lt;/a&gt;.&lt;/p&gt;
&lt;h4 id=&#34;versions&#34;&gt;Versions&lt;/h4&gt;
&lt;p&gt;ADxMenu3 comes in three flavors.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Standard&lt;/strong&gt; version is for sites with no forms (at least no select boxes in forms), and for small menus. Long menus tend to fall out of the visible part of the screen, which is not very user friendly.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Professional&lt;/strong&gt; version builds on the standard, adding &lt;a href=&#34;https://aplus.rs/wch/intro/&#34;&gt;WCH&lt;/a&gt; implementation. That means that your menus will be placed above any form element on the page, including the select boxes in IE (the usual problem). Again, make sure your menus fit in the reasonable desktop size.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Enterprise&lt;/strong&gt; is intended for sites with long submenus. For sites where you must be sure that menu stays visible. It includes additional scripting which checks for menu position and moves it in the opposite direction if it&amp;rsquo;s off-screen. It&amp;rsquo;s clearly the best choice for commercial sites, unless you are sure that your menus will always fit in the visible part. If you are, then you are better off with one of two lighter versions, as you will have smaller download foot-print.&lt;/p&gt;
&lt;p&gt;Switching between versions is easy, as &lt;em&gt;CSS and HTML markup are same&lt;/em&gt; for all of them. What changes is the accompanying scripts and the code you use to include the files. Instructions for all of this can be found on the &lt;a href=&#34;https://aplus.rs/adxmenu/intro/&#34;&gt;Intro&lt;/a&gt; page.&lt;/p&gt;
&lt;h4 id=&#34;accessibility-issues&#34;&gt;Accessibility issues&lt;/h4&gt;
&lt;p&gt;These menus are always branded as utterly non-accessible. True, they depend on the precise movement of your mouse, thus making it inaccessible for people with disabilities, as they will have a hard time fetching items in the second or third nested submenu.&lt;/p&gt;
&lt;p&gt;However, this is &lt;em&gt;not the problem with the menu&lt;/em&gt; itself. It&amp;rsquo;s with the site IA designer.&lt;/p&gt;
&lt;p&gt;Online shop is the typical example. You start with merchandise types (books, games, music etc.). Then when you click on &amp;ldquo;books&amp;rdquo; you could have Latest, Most popular, A-Z, Recommended, etc. You need to build such site to be usable with simple links - no menus or search. Only then you can think about drop menus.&lt;/p&gt;
&lt;p&gt;So, each item that has submenu must itself be linked to a page that contains &amp;ldquo;normal&amp;rdquo; list of items from that submenu. By doing this, you solve not only mentioned accessibility issues but are also supporting older browsers. The way CSS is included (&lt;code&gt;@import&lt;/code&gt;) prevents very old browsers like Navigator 4 or IE4 to even see the styled menu.&lt;/p&gt;
&lt;p&gt;On the other hand, browsers like IE5/Mac or Opera 6 have decent CSS1 support, thus being able to see and load menu .css files. Due to use of CSS2 advanced selectors, they will never show the submenus, thus creating usability problems &lt;strong&gt;if&lt;/strong&gt; you do not link the main items to appropriate pages.&lt;/p&gt;
&lt;p&gt;Always think deep about your site IA. Using ADxMenu as the only source of site nav will only get you in trouble. Use it to speed navigation up. That is its purpose. That is where it shines.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>New ADxMenu in sight</title>
      <link>https://aplus.rs/2004/new-adxmenu-in-sight/</link>
      <pubDate>Fri, 19 Nov 2004 15:07:23 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/new-adxmenu-in-sight/</guid>
      <description>&lt;p&gt;You might&amp;rsquo;ve not noticed, but &lt;a href=&#34;https://aplus.rs/adxmenu/examples/&#34;&gt;beta version&lt;/a&gt; of &lt;a href=&#34;https://aplus.rs/adxmenu/intro/&#34;&gt;ADxMenu 3&lt;/a&gt; is up since the new blog was published. There are still loose ends in the enterprise version, but the hardest part is over and I can proudly say that it promises to be &lt;strong&gt;the&lt;/strong&gt; menu, for all sites and possible uses.&lt;/p&gt;
&lt;p&gt;Highlights:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;submenus can freely go one over another, even in IE (no unwanted overlap anymore)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;clean separation of IE hacks in separate .css file, which only IE loads&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;reworked whatever:hover so it deals only with menu elements (no page-onload freeze anymore)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;three different version, so you can pick what suits you best&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;mildly simpler CSS&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I&amp;rsquo;ll be away this weekend, but you can expect full write-up next week. Until then, please report errors you find (and in which browser, version) in comments.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>There&#39;s some light at the far end...</title>
      <link>https://aplus.rs/2004/theres-some-light-at-the-far-end/</link>
      <pubDate>Tue, 28 Sep 2004 15:41:29 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/theres-some-light-at-the-far-end/</guid>
      <description>&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/adxmenu-tease.png&#34; alt=&#34;cooking up&amp;hellip;&#34;&gt;&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Four variants of drop-down menu</title>
      <link>https://aplus.rs/2004/four-variants-of-drop-down-menu/</link>
      <pubDate>Thu, 08 Jul 2004 13:26:27 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/four-variants-of-drop-down-menu/</guid>
      <description>&lt;p&gt;It seems like years&amp;hellip;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/adxmenu.png&#34; alt=&#34;ADxMenu&#34;&gt;&lt;/p&gt;
&lt;p&gt;Having established (or so I thought) the basis for good, versatile, menu system, I figured it&amp;rsquo;s about time to make it truly powerful. I wanted it to:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;be placed anywhere and to open-up in any direction&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;work in CSS2-capable browsers and IE5+/Win&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;provide b-version script for use with other browsers (mostly IE5/Mac)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;circumvent the drop-down problem on IE/Win&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;avoid scroll bars upon page load (while menus are hidden)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;prevent IE from drawing tall submenus over prev/next parent menu options&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Well, I did &lt;em&gt;all&lt;/em&gt; that, and I did &lt;em&gt;none&lt;/em&gt; of that.&lt;/p&gt;
&lt;h5 id=&#34;basis&#34;&gt;Basis&lt;/h5&gt;
&lt;p&gt;For those of you late-arrivals to the party, this menu uses nested link list as its HTML, and then uses a bit of CSS to provide the drop-down menu.&lt;/p&gt;
&lt;p&gt;Then, on top of that, it uses a bit of Javascript for the following tasks:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;prevent HTML select boxes to go over submenu, in IE/Win (using my &lt;a href=&#34;https://aplus.rs/wch/&#34;&gt;WCH&lt;/a&gt; script)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;keep the menu inside the visible portion of the window area (reposition)&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;First task was thought to be easy. WCH script, in its 3rd version, is stable, heavily tested and used on a variety of web sites I built. Well, while implementing some of the requirements for this version, IE caught me with my pants down. Read on to see how.&lt;/p&gt;
&lt;p&gt;Second task dragged me into the hell of incomplete CSS-P/DOM implementations and an amazing array of browser bugs. The most amazing part was that browser with least problems (if any) was IE/Win. All those nice, modern, standard-compliant browsers were tripping me every inch of the way. Read on to see how.&lt;/p&gt;
&lt;p&gt;In some cases, even the mere task of drawing the main menu was not possible (now, this was IE).&lt;/p&gt;
&lt;h5 id=&#34;version-25&#34;&gt;Version 2.5&lt;/h5&gt;
&lt;p&gt;I thought that this would be version 3, but due to unfulfilled goals, it had to be downgraded.&lt;/p&gt;
&lt;p&gt;The HTML structure remains the same: nested ULs, with As in each LI. For IE/Win, &lt;code&gt;csshover.htc&lt;/code&gt; is used to simulate &lt;code&gt;li:hover&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;CSS has changed a bit, but not that much. I&amp;rsquo;ll repeat the basic instructions, and leave you to dissect the examples and build your own designs.&lt;/p&gt;
&lt;p&gt;Main example for this version is using WinXP look, and I provided the following variants:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;HBT: horizontal main menu, submenus drop-down (top to bottom)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;HTB: horizontal main menu, submenus drop-up (bottom to top)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;VLR: vertical main menu, submenus drop-right (left to right)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;VRL: vertical main menu, submenus drop-left (right to left)&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;This is the only menu style featuring all variants, both pure-CSS and scripted. I picked this one because it&amp;rsquo;s the most complicated style I could think of. Its items (LI) have margins, paddings, borders and icons - all possible causes for various (re)positioning problems. If this is ever made to work properly, then any other style would work by itself.&lt;/p&gt;
&lt;p&gt;All other examples have only HTB variant; the task of keeping all of them up-to-date is taking way more time then I&amp;rsquo;m able to put aside for this.&lt;/p&gt;
&lt;h5&gt;&lt;/h5&gt;
&lt;p&gt;HTML code&lt;/p&gt;
&lt;p&gt;HTML is very simple so I won&amp;rsquo;t go into details. I only want to emphasize one important bit I kept forgetting in previous write ups. Wrapping &lt;code&gt;div&lt;/code&gt; and each &lt;code&gt;ul&lt;/code&gt; &lt;strong&gt;must&lt;/strong&gt; have an &lt;code&gt;id&lt;/code&gt; attribute. It is essential for WCH script to function properly. Also, you must place &lt;code&gt;class=&amp;quot;submenu&amp;quot;&lt;/code&gt; on each &lt;code&gt;a&lt;/code&gt; element followed by nested list.&lt;/p&gt;
&lt;h5 id=&#34;css-core&#34;&gt;CSS core&lt;/h5&gt;
&lt;p&gt;This is brief walk-through of the CSS build-up for all menu variants. In actual menu&amp;rsquo; .css files, this part is denoted as &lt;em&gt;Basic style&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;Horizontal main menus are made of floated list items, so if you want to have a background/border on it, you need to provide the appropriate &lt;code&gt;height&lt;/code&gt; value. Since this is highly dependent on design (done in &lt;em&gt;Make-up&lt;/em&gt; part of the .css), you should do it there.&lt;/p&gt;
&lt;p&gt;For vertical menus, same counts for &lt;code&gt;width&lt;/code&gt;, or your menu would take up all available width.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;c&#34;&gt;/*
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c&#34;&gt;	height: ??;		Hxx
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c&#34;&gt;	width: ??;		Vxx
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c&#34;&gt;	*/&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;display&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;block&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Then remove all list-specific attributes. List items are blocked, floated and relatively positioned, so that submenus can happily open next to their parent item. &lt;code&gt;float:left&lt;/code&gt; part is not needed for vertical menus, but that can depend on your design and HTML code.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;margin&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;padding&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;border&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;list-style-type&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;none&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;margin&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;padding&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;border&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;display&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;block&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;float&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;relative&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Then turn links into blocks, to have more fun when styling. The second rule is for IE, mainly IE6 and it is there to fix its inability to expand clickable area. Although it visually do that by itself, link-click functionality exists only on actual text of the link. It seems that changing &lt;code&gt;position&lt;/code&gt; fixes this - &lt;a href=&#34;../adxmenu2-pure-CSS-multilevel-menus/#349&#34;&gt;great find&lt;/a&gt; by Douglas Clayton.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;display&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;block&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;o&#34;&gt;*&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;html&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;relative&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;All submenus are hidden initially. Best way to do this is to completely remove them, using &lt;code&gt;display:none&lt;/code&gt;, so there are no unnecessary scroll bars. It works as it should, for all but IE due to a whole array of problems, explained further below.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;visibility&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;hidden&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;absolute&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;z-index&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;10&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nt&#34;&gt;html&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;&amp;gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;body&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;display&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;none&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Each submenu list item should be 100% wide, so that menus look like menus. Again, thanks to wonderfully non-practical &lt;a href=&#34;http://www.w3.org/TR/REC-CSS2/box.html&#34;&gt;W3C box model&lt;/a&gt;, this is possible only if you don&amp;rsquo;t have paddings on LIs. If you do (like I have in WinXP style), then you need to tweak this in the make-up part.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;100&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;%&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now comes the part responsible for menu acting as menu. First, set the position of the submenu, in respect to its parent item and in respect to direction in which you want it to open up.&lt;/p&gt;
&lt;p&gt;For horizontal menus, 1st submenu will open as needed, by default. The rest of them needs a tweak. For HTB variant, it should open on the right of the parent item, so it goes like this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;top&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;100&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;%&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;For HBT (drop-up), bottom edge of the 1st submenu needs to be moved up a bit. The value of bottom highly depends on the make-up style, so be ready to tweak it as needed.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;bottom&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mf&#34;&gt;1.5&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;em&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;bottom&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;100&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;%&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;VLR variant is the same as HTB, expect the selector is one way down - it applies to the 1st submenu as well.&lt;/p&gt;
&lt;p&gt;This also illustrates the solution for the problem that sometimes appears, when on initial page load huge (more or less) horizontal scroll bar appears. This way, at initial page load, all menus are in top-left corner (of the page or of the parent list item). This can be applied to all variants, not just VLR.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;top&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;top&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;100&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;%&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Finally, for VRL variant:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;top&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;top&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;-100&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;%&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Last bit is show/hide. Since IE does not support child selector, we need to simulate it. Add as many levels of this, as needed. Number of lines (or number of &lt;code&gt;li:hover&lt;/code&gt;s) should equal the nesting level.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;visibility&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;visible&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nt&#34;&gt;div&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;visibility&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;hidden&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The following rule is for browsers supporting CSS2 selectors, with increased specificity (to override the previous simulation for IE).&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menuList&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;&amp;gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;display&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;block&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;visibility&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;visible&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h5 id=&#34;examples&#34;&gt;Examples&lt;/h5&gt;
&lt;p&gt;As usual, examples can be &lt;a href=&#34;../examples2/&#34;&gt;found here&lt;/a&gt;, also linked from the side column. As said previously, WinXP style offers both pure CSS and scripted version. First ones should be used on simple pages and with simple menus. If your page has select boxes or you have long menus, then you are better off with scripted version. Scripteds are an upgrade of the pure CSS variant - you just add links to two scripts and the following line of Javascript:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;ADXM&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;Add&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;menuList&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;H&amp;#34;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;);&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;First parameter is the &lt;code&gt;id&lt;/code&gt; of the main UL (&lt;em&gt;not&lt;/em&gt; the wrapping DIV). Second parameter is either &amp;ldquo;H&amp;rdquo; or &amp;ldquo;V&amp;rdquo;, specifying the type of menu. It is optional - if this is anything other then &amp;ldquo;V&amp;rdquo;, it will be treated as &amp;ldquo;H&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;Also, for CSS validity reasons, note that csshover.htc is removed from the .css and placed inside of &lt;a href=&#34;http://msdn.microsoft.com/library/default.asp?url=https://aplus.rs/workshop/author/dhtml/overview/ccomment_ovw.asp&#34;&gt;IE&amp;rsquo;s own&lt;/a&gt; conditional &lt;a href=&#34;http://www.dithered.com/css_filters/html_only/conditional_comments_ie.html&#34;&gt;comments&lt;/a&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;!--[if lte IE 6]&amp;gt;

&amp;lt;style type=&amp;quot;text/css&amp;quot;&amp;gt;

body { behavior:url(&amp;quot;csshover.htc&amp;quot;); }

&amp;lt;/style&amp;gt;

&amp;lt;![endif]--&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This is an example - you make sure that path from HTML document to .htc is correct.&lt;/p&gt;
&lt;p&gt;There is also an &lt;a href=&#34;../examples2b/&#34;&gt;example&lt;/a&gt; of b-version of the script. Here, the script takes the role that csshover.htc had - this can be used on long pages (where .htc freezes the page) and if you need to support IE5/Mac (or any other browser without &lt;code&gt;li:hover&lt;/code&gt; support).&lt;/p&gt;
&lt;h5 id=&#34;weirdness-anger-despair&#34;&gt;Weirdness, anger, despair&amp;hellip;&lt;/h5&gt;
&lt;p&gt;For the longest time, I thought is it really worth it to publish this. What won me over is the fact that best menus are simple menus, where most of problems would not show and when menus actually work quite nice.&lt;/p&gt;
&lt;p&gt;For the sake of information and for the hope that some of you might solve one or few of the problems, here it comes. First the problems appearing in the pure CSS, and then those in the scripted version.&lt;/p&gt;
&lt;h6 id=&#34;opera-75x-weirdness-pure&#34;&gt;Opera 7.5x weirdness (pure)&lt;/h6&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/htb-opera.png&#34; alt=&#34;Opera 7.5x problem&#34;&gt;&lt;/p&gt;
&lt;p&gt;When 3rd level submenu is opened in Opera, you get the display as shown. I tried this with latest Opera (7.52). It happens with all variants, in pure and scripted version. You don&amp;rsquo;t even need to move the mouse over that submenu - hover its parent item (&lt;em&gt;Hardware&lt;/em&gt;) then move the mouse down to &lt;em&gt;Electronics&lt;/em&gt; - the submenu will stay visible in its messed form.&lt;/p&gt;
&lt;p&gt;If some of you don&amp;rsquo;t find a solution, I will post this as a bug to Opera Software.&lt;/p&gt;
&lt;h6 id=&#34;box-model-problems-in-ie50&#34;&gt;Box model problems in IE5.0&lt;/h6&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/ie50-vlr.png&#34; alt=&#34;display of VLR variant in IE5.0&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/ie50-vrl.png&#34; alt=&#34;display of VRL variant in IE5.0&#34;&gt;&lt;/p&gt;
&lt;p&gt;Due to different (better if you ask me) box model, IE5.0 has slightly different display. Shorter item is due to &lt;code&gt;padding-left:29px&lt;/code&gt;. I did not want to fix this, as it is not creating functionality problems.&lt;/p&gt;
&lt;p&gt;Also note the taller main items, because of white space bug. To fix this, you need to either float the items or connect list items on one line (in .html).&lt;/p&gt;
&lt;p&gt;This is probably happening in 5.5 two, but I had no chance to even take a look at it, because&amp;hellip;&lt;/p&gt;
&lt;h6 id=&#34;vertical-weirdness-in-ie-55&#34;&gt;Vertical weirdness in IE 5.5&lt;/h6&gt;
&lt;p&gt;&amp;hellip;of this fine behavior in it.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/ie55-vlr.png&#34; alt=&#34;display of VLR variant in IE5.5&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/ie55-vrl.png&#34; alt=&#34;display of VRL variant in IE5.5&#34;&gt;&lt;/p&gt;
&lt;p&gt;No comment.&lt;/p&gt;
&lt;h6 id=&#34;hbt-impossible-in-ie50&#34;&gt;HBT impossible in IE5.0&lt;/h6&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/ie50-hbt.png&#34; alt=&#34;problematic display of HBT variant in IE5.0&#34;&gt;&lt;/p&gt;
&lt;p&gt;This is the problem I covered before. If you replace &lt;code&gt;visibility&lt;/code&gt; with &lt;code&gt;display&lt;/code&gt;, then it sort of gets itself in order. But IE has other problems with display&amp;hellip;&lt;/p&gt;
&lt;h6 id=&#34;safari-bug-1&#34;&gt;Safari bug 1&lt;/h6&gt;
&lt;p&gt;Horizontal menus in Safari have no background on hover, because the main menu items are floated. If you remove the float (or take a look at vertical variants) then all is well. My Safari is 1.2.2 (v125.8).&lt;/p&gt;
&lt;p&gt;Background color does appear when Safari is forced to withdraw the screen; if you open Hardware submenu, scroll bar usually appears and then highlighted state shows up.&lt;/p&gt;
&lt;h6 id=&#34;safari-bug-2&#34;&gt;Safari bug 2&lt;/h6&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/safari-liposproblem.png&#34; alt=&#34;Safari problem with :hover change of position&#34;&gt;&lt;/p&gt;
&lt;p&gt;In the first tests, when I was playing with the following combination:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu li { position: static; }

#menu li:hover { position: relative; }
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;hellip;I got another problem with Safari. It will show the submenu properly, but fail to remove them from the screen on mouse-out.&lt;/p&gt;
&lt;h6 id=&#34;overlapping-in-ie&#34;&gt;Overlapping in IE&lt;/h6&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/ie-posrel.png&#34; alt=&#34;phone-book problem&#34;&gt;&lt;/p&gt;
&lt;p&gt;The best part from the previous version is now lost. The CSS bit from above (in Safari bug 2), had one fabulous benefit in IE: it prevented &lt;a href=&#34;https://aplus.rs/Techs/24/&#34;&gt;idiotic overlapping&lt;/a&gt; of the menus. But the fact that items were static caused their submenus to be initially placed outside of the screen, thus introducing hor. scrolls.&lt;/p&gt;
&lt;p&gt;Horror is totally unleashed in scripted version.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/ie-repos.png&#34; alt=&#34;phone-book problem at its worst&#34;&gt;&lt;/p&gt;
&lt;p&gt;Why did I change this back to lousy variant? Because of Safari bug? No. Read on.&lt;/p&gt;
&lt;h6 id=&#34;overflowauto-scripted&#34;&gt;overflow:auto (scripted)&lt;/h6&gt;
&lt;p&gt;If you have a rather long menu, and an unusually small screen, then you might end up in the situation where your submenu is taller then available viewport (same applies for very wide menus). Natural thing to try here is to set the submenu&amp;rsquo;s &lt;code&gt;overflow&lt;/code&gt; property to &lt;code&gt;auto&lt;/code&gt;, enlarge the width (height) of it for some safe value to cover the width of the scroll bars and then let the user scroll.&lt;/p&gt;
&lt;p&gt;Not possible my brother - as soon as overflow is applied, &lt;strong&gt;all&lt;/strong&gt; browsers fire mouseout event and your menus disappear.&lt;/p&gt;
&lt;h6 id=&#34;firefox-and-opera-hbt-scripted&#34;&gt;Firefox and Opera, HBT (scripted)&lt;/h6&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/hbt-firefox.png&#34; alt=&#34;wiiieeeerd&amp;hellip;&#34;&gt;&lt;/p&gt;
&lt;p&gt;Firefox and Opera 7.5 were the only browsers (outside of IE) where repositioning worked as it should. Except this problem with drop-up menu (screen shows the state after repositioning). The visible part finishes at the exact point where bottom edge of the submenu was, before it was moved down.&lt;/p&gt;
&lt;p&gt;Since both browsers behave identically, this might be my error, although I can&amp;rsquo;t seem to find it.&lt;/p&gt;
&lt;h6 id=&#34;nn71-and-safari-scripted&#34;&gt;NN7.1 and Safari (scripted)&lt;/h6&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/nn71.png&#34; alt=&#34;incomplete DOM implementation in NN7.1&#34;&gt;&lt;/p&gt;
&lt;p&gt;Both of these had to be excluded from the script, because of incomplete DOM implementation. Safari has even worse problems, ones I can only describe as erratic. It still has a long way to go. Don&amp;rsquo;t know about you &lt;a href=&#34;http://weblogs.mozillazine.org/hyatt/index.html&#34;&gt;Dave&lt;/a&gt;, but to me this seems more important than &lt;a href=&#34;http://weblogs.mozillazine.org/hyatt/archives/2004_07.html#005913&#34;&gt;proprietary HTML extensions&lt;/a&gt;.&lt;/p&gt;
&lt;h6 id=&#34;ie-mayhem&#34;&gt;IE mayhem&lt;/h6&gt;
&lt;p&gt;Welcome.&lt;/p&gt;
&lt;p&gt;Remember &lt;a href=&#34;https://aplus.rs/browsers/i-hate-this-thing-called-IE/&#34;&gt;this entry&lt;/a&gt;? IE = P(iece) o(f) C(rap)? Here is the drop(s) that pushed me over the top.&lt;/p&gt;
&lt;p&gt;Before all, comes the simulation of &lt;code&gt;li:hover&lt;/code&gt; with csshover.htc and simulation of &lt;code&gt;li&amp;gt;ul&lt;/code&gt;, as explained in the CSS walk-through above. That .htc is basically Javascript, run on page load. As such, it takes some time to be executed, so it can&amp;rsquo;t be used on very long pages.&lt;/p&gt;
&lt;p&gt;What it does is that it adds &lt;code&gt;onmouseover&lt;/code&gt; and &lt;code&gt;onmouseout&lt;/code&gt; event handlers for LI in the menu and also dynamically creates special classes that are identical to &lt;code&gt;li:hover&lt;/code&gt; rules in the CSS. First handler changes the class of the LI to corresponding class. That also takes time. It might be milliseconds, but it still takes time. Remember that.&lt;/p&gt;
&lt;p&gt;Now one part of the answer why I gave up the solution for overlapping.&lt;/p&gt;
&lt;p&gt;Changing the &lt;code&gt;position&lt;/code&gt; property for the element is also done in runtime, in about the same moment as previous class switch is done, right after that actually, if I&amp;rsquo;m not mistaken. Remember this as well.&lt;/p&gt;
&lt;p&gt;Now, the second part of the answer.&lt;/p&gt;
&lt;p&gt;My &lt;em&gt;ADxMenu.js&lt;/em&gt; script, adds another onmouseover/onmouseout pair of handlers. For IE, those handlers call &lt;em&gt;WCH.js&lt;/em&gt; (to hide select boxes), as well as repositioning function. Both WCH and repos needs to know what coordinates they will use when calculating the menu position. Third remember.&lt;/p&gt;
&lt;p&gt;Well, if you combine those three bits I told you to remember, you will get highly unstable situation, where God knows in what order they will be executed. They need to be done in the exact order I lay them out here, or the repos will not work and WCH&amp;rsquo;s iframe will be created in the wrong place.&lt;/p&gt;
&lt;p&gt;Completely uncontrollable situation. &lt;em&gt;But the show does not stop.&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;It goes on when you try to use &lt;code&gt;display&lt;/code&gt; instead of &lt;code&gt;visibility&lt;/code&gt;. In order for any element to have a programmatically fetchable size and position, it must have &lt;code&gt;display&lt;/code&gt; value other than &lt;code&gt;none&lt;/code&gt;. My .css changes this value in runtime, on mouse over.&lt;/p&gt;
&lt;p&gt;Remember those three bits again and add this one. Apparently IE can&amp;rsquo;t do class switch in time for the repos and WCH scripts, so they happily return zeros or nothing for the submenu&amp;rsquo; size and position. Lovely. You try to fix one problem and bump into another. And another. It never ends.&lt;/p&gt;
&lt;p&gt;I tried several tricks.&lt;/p&gt;
&lt;p&gt;Changing the position using JS, not CSS, did not helped at all. It behaved the same. Changing WCH to check the runtime value of &lt;code&gt;display&lt;/code&gt; property (and if it is not, to force it) yielded very interesting results: returned value was &lt;code&gt;block&lt;/code&gt;, but it behaved as it is not. This was too much.&lt;/p&gt;
&lt;p&gt;All in all, this is one hell of a mess. Use it as you dare, on your own risk. Be prepared to anything. And please report back any ideas and solutions you might have.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Drop-up menu</title>
      <link>https://aplus.rs/2004/drop-up-menu/</link>
      <pubDate>Sat, 01 May 2004 21:51:54 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/drop-up-menu/</guid>
      <description>&lt;p&gt;Due to popular request (hi xeon :), I have updated the examples with the &lt;a href=&#34;https://aplus.rs/adxmenu/examples2/minitabs/indexdp.html&#34;&gt;drop-up&lt;/a&gt; version. This is useful if you want to place the menus in the page footer.&lt;/p&gt;
&lt;p&gt;This is the only important part:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;c&#34;&gt;/* fix the position */&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;bottom&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mf&#34;&gt;1.5&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;em&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;bottom&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;0&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;100&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;%&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;1.5em is just an example value. You need to modify it according to menu make-up (as shown in the examples).&lt;/p&gt;
&lt;p&gt;Good to have in mind is that usability script will not be much help here, as it checks for menu going below the viewport&amp;rsquo;s bottom, while here we need to check for going above the viewport&amp;rsquo;s top. I will make sure that future revision of the script deals with this situation. It&amp;rsquo;s not hard, I just need to find time to do it.&lt;/p&gt;
&lt;p&gt;There is one more change, due to some wierdness in IE 5.0x on Windows. I had to use &lt;code&gt;display&lt;/code&gt; instead of &lt;code&gt;visibility&lt;/code&gt; because the latter creates huge problems in IE. Main menu is totally broken, probably because IE is acting like the submenus are not absolutely positioned at all. This way, wierdness is limited only when item is hovered.&lt;/p&gt;
&lt;p&gt;Also, I gave the better explanation how to extend the styles to have more submenu levels, in the &lt;a href=&#34;../adxmenu2-pure-css-multilevel-menus/&#34;&gt;pure CSS menus&lt;/a&gt; post.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>csshover.htc and IE freeze</title>
      <link>https://aplus.rs/2004/csshoverhtc-and-ie-freeze/</link>
      <pubDate>Mon, 19 Apr 2004 19:33:52 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/csshoverhtc-and-ie-freeze/</guid>
      <description>&lt;p&gt;When I tried to implement csshover.htc-enabled ADxMenu on the client website, I was greeted with very unpleasant behavior. On the very long page or complicated page, IE would freeze for a period of 10-15s. Download stops, but it does not give you the control over page until it finishes processing. Don&amp;rsquo;t know what exactly it&amp;rsquo;s doing, but I guess it might be going through complete document tree, for each new hover rule. Or I could be spitting nonsense.&lt;/p&gt;
&lt;p&gt;Whatever it is, it was unbearable. Hence the version 2b.&lt;/p&gt;
&lt;p&gt;I didn&amp;rsquo;t do anything spectacular. First, I reincarnated the double style rules - one for IE, one for all other:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu li:hover,

* html #menu li.&amp;lt;strong&amp;gt;iehover&amp;lt;/strong&amp;gt; {

	...

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Then in the script, for each &lt;code&gt;li&lt;/code&gt; element, I added the class changing code, shown here and there over the Net:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;oMenuLI.onmouseover = function() {

	this.className += &amp;quot; iehover&amp;quot;;

};

oMenuLI.onmouseout = function() {

	this.className = 

		this.className.replace(&amp;quot; iehover&amp;quot;, &amp;quot;&amp;quot;);

};
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;All else is identical to existing menus. For those who want to have perfectly valid CSS files, this script is the way to go.&lt;/p&gt;
&lt;p&gt;I took the opportunity to implement WCH3. All 2.x examples are updated to use WCH3 and latest corresponding versions of ADxMenu script.&lt;/p&gt;
</description>
    </item>
    
    <item>
      <title>Vertical menu examples</title>
      <link>https://aplus.rs/2004/vertical-menu-examples/</link>
      <pubDate>Mon, 19 Apr 2004 13:07:04 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/vertical-menu-examples/</guid>
      <description>&lt;p&gt;I received several e-mail requests to create vertical examples of the menus. During the Easter holidays I did them, but had no time to write event the shortest entry afterwards. (Is it just me or the amount of work that piles up while being on any holiday is so big that quickly burns any freshness from it?)&lt;/p&gt;
&lt;p&gt;So, not to delay this anymore, I have created &lt;a href=&#34;../examples/&#34;&gt;vertical examples&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Changes are few. What I did was to move the basic CSS rules used for submenus to the main menu as well, and re-style the main menu so that it sits comfortably at the left side.&lt;/p&gt;
&lt;p&gt;#menu li {
margin: 0;
padding: 0;
border: 0;
&lt;strong&gt;width: 100%;&lt;/strong&gt;
display: block;
float: left;
&lt;strong&gt;position: static;&lt;/strong&gt;
}
&lt;strong&gt;html&amp;gt;body #menu li&lt;/strong&gt; {
float: none;
position: relative;
}&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&amp;lt;strong&amp;gt;#menu li:hover&amp;lt;/strong&amp;gt; {
	position: relative;
}

&amp;lt;strong&amp;gt;#menu li ul&amp;lt;/strong&amp;gt; {
	top: 0;
	left: 100%;
}

#menu {
	...&amp;lt;strong&amp;gt;
	width: 120px;
	height: auto;
&amp;lt;/strong&amp;gt;
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Stronged parts are the essential changes. Rest of the changes in the actual menu&amp;rsquo;s CSS is just designs. You should make sure, as shown above, that height is not restricted and that width is restricted, because the &lt;code&gt;LI&lt;/code&gt;s have 100% width.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ADxMenu2 - the usability script</title>
      <link>https://aplus.rs/2004/adxmenu2-the-usability-script/</link>
      <pubDate>Tue, 09 Mar 2004 16:22:19 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/adxmenu2-the-usability-script/</guid>
      <description>&lt;p&gt;There are situations when the drop-down multilevel menu will go outside the visible area of the page. It is either too long or has two or three sub levels (I certainly don&amp;rsquo;t recommend more than that).&lt;/p&gt;
&lt;p&gt;Such menu is highly unusable and there are two solutions:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Re-arrange the layout elements so that menu fits on the page in reasonable space&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Apply the script that will reposition the menu&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/reposition.png&#34; alt=&#34;An example of bad and good user experience&#34;&gt;&lt;/p&gt;
&lt;h5 id=&#34;script-dependencies&#34;&gt;Script dependencies&lt;/h5&gt;
&lt;p&gt;Calculating element position on the page is still in the art-form stage. Browser line in use today is not always up to the task. Sad thing is that you can&amp;rsquo;t check for certain element or property and be sure that script will work. Buggy or partial implementation of certain elements is the real problem. A problem that leads to ugly browser detection.&lt;/p&gt;
&lt;p&gt;For example, Gecko browsers have complete (in terms of what I needed so far) positioning support from version 1.5 (Firebird 0.7). Previous version were fine when you used CSS-P purely. If you look at &lt;a href=&#34;../examples2/winxp/&#34;&gt;this example&lt;/a&gt; you will see that sub menus appear where they are supposed to.&lt;/p&gt;
&lt;p&gt;But when you want to set the position through DOM, you have problems as illustrated in the following figure. 1.4 version of Gecko core is used by the last Netscape-branded browser (7.1) so this problem is here to stay. :(&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://aplus.rs/images/adxmenu/cssp-problem.png&#34; alt=&#34;positioning problem&#34;&gt;&lt;/p&gt;
&lt;p&gt;Apple web kits prior to version 101 (I think) also have this problem, so Safari 1.0 and Omniweb suffer from it. Safari 1.2 is fine and I hope that final version of Omniweb 5 will fix this as well. Additionaly, it does not work in Opera 7.23.&lt;/p&gt;
&lt;p&gt;Problem is that, when you do &lt;code&gt;object.style.left = &amp;quot;0px&amp;quot;&lt;/code&gt;, that 0 is not the &lt;code&gt;(0,0)&lt;/code&gt; point of the positioned parent, but that of the whole page (of body).&lt;/p&gt;
&lt;p&gt;So, this script must check the browser version to make sure that everything would work as expected. That is one major dependence.&lt;/p&gt;
&lt;p&gt;Another is technical. Previous version of ADxMenu was dependent on three other scripts. In this version, I removed all of them.&lt;/p&gt;
&lt;h5 id=&#34;onload-execution&#34;&gt;Onload execution&lt;/h5&gt;
&lt;p&gt;In the previous version, I used AttachEvent script to do necessary work on page load. I like that script because &lt;strong&gt;I know&lt;/strong&gt; the order of onload-scripts execution. ADxMenu is not dependent on the order anymore, as the basic menu functionality is achieved using only CSS.&lt;/p&gt;
&lt;p&gt;This entry is updated (May 6th) to be compatible with latest ADxMenu.&lt;/p&gt;
&lt;p&gt;Therefore, I could safely use event listeners already existing in the browsers (you&amp;rsquo;ll shortly see what ADXM is).&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;if (window.addEventListener) {

	window.addEventListener(&amp;quot;load&amp;quot;, ADXM.Init, false);

} else if (window.attachEvent) {

	window.attachEvent(&amp;quot;onload&amp;quot;, ADXM.Init);

}

if (window.addEventListener) {

	window.addEventListener(&amp;quot;resize&amp;quot;, ADXM.Viewport, false);

} else if (window.attachEvent) {

	window.attachEvent(&amp;quot;onresize&amp;quot;, ADXM.Viewport);

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;It also acts as yet another browser detect.&lt;/p&gt;
&lt;h5 id=&#34;dom-library&#34;&gt;DOM library&lt;/h5&gt;
&lt;p&gt;As before, I use &lt;a href=&#34;http://cross-browser.com/x/&#34;&gt;X library&lt;/a&gt; from Mike Foster. Only this time I moved the functions I use to the ADxMenu script. If you use X-lib for anything else and have it already included in the page, then just delete that part of the script.&lt;/p&gt;
&lt;h5 id=&#34;drop-down-field-problem-in-iewin&#34;&gt;Drop-down field problem in IE/Win&lt;/h5&gt;
&lt;p&gt;You are certainly aware of the problem with form drop-down fields showing through the layers. I have recoded the menu script so that it checks for existence of WCH functions before it calls them. That way, you can include or not include the WCH script - menu script will work either way. It is good not to include it if you don&amp;rsquo;t have drop-downs or other windowed controls on the page (saves one HTTP request and some download time).&lt;/p&gt;
&lt;h5 id=&#34;usage&#34;&gt;Usage&lt;/h5&gt;
&lt;p&gt;I have simplified the way script works (or so I believe). During page loading, it will create an object, &lt;code&gt;ADXM&lt;/code&gt;, that has certain properties and methods.&lt;/p&gt;
&lt;p&gt;How to use it?&lt;/p&gt;
&lt;p&gt;Include the script in the page, and add your menus with lines such as this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;ADXM.Add( &amp;quot;menuList&amp;quot;, &amp;quot;H&amp;quot; );
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;code&gt;menuList&lt;/code&gt; is the ID of the main menu UL element. Second parameter defines whether main menu is horizontal (&amp;ldquo;H&amp;rdquo;) or vertical (&amp;ldquo;V&amp;rdquo;).&lt;/p&gt;
&lt;p&gt;Update: If you are using WCH along with menu script, each UL in the menu &lt;strong&gt;must have an unique ID&lt;/strong&gt;. Without the IDs, WCH will not work as expected. Kudos to Koen Calliauw for reporting this back.&lt;/p&gt;
&lt;h5 id=&#34;how-it-works&#34;&gt;How it works&lt;/h5&gt;
&lt;p&gt;All added menus will be processed on page load. Viewport size will be saved (this is also done on each resize). Then script process all menu items and adds appropriate handlers to sub menu actuators.&lt;/p&gt;
&lt;p&gt;On hover, it calculates the position where menu should be, and then checks for available space until the bottom and right viewport edge. If there is not enough space, it moves the submenu in the opposite direction.&lt;/p&gt;
&lt;p&gt;Take a look at the &lt;a href=&#34;../examples2/&#34;&gt;examples&lt;/a&gt; - follow the &amp;ldquo;full script&amp;rdquo; links. Please report any positioning problems you encounter.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>ADxMenu2 - pure CSS multilevel menus</title>
      <link>https://aplus.rs/2004/adxmenu2-pure-css-multilevel-menus/</link>
      <pubDate>Sat, 06 Mar 2004 17:34:23 +0000</pubDate>
      
      <guid>https://aplus.rs/2004/adxmenu2-pure-css-multilevel-menus/</guid>
      <description>&lt;p&gt;A new way to accomplish multilevel menus without the Javascript. Peter Nederlof has created a &lt;a href=&#34;http://www.xs4all.nl/~peterned/csshover.html&#34;&gt;behavior&lt;/a&gt; that adds arbitrary :hover support for IE/Win. That means that IE will now recognize &lt;code&gt;li:hover&lt;/code&gt;, thus giving us more degrees of freedom for menu creation.&lt;/p&gt;
&lt;p&gt;That means that basic functionality does not depend on user&amp;rsquo;s preference regarding Javascript. You can include the script only if you want to add additional usability features: off-screen positioning check, as well as placing menus over drop-downs (WCH).&lt;/p&gt;
&lt;p&gt;I have slightly changed the way CSS is built. All of them now depend on &lt;code&gt;li:hover&lt;/code&gt;. Peter&amp;rsquo;s behavior deals with IE&amp;rsquo;s lack of support, but only on windows. That means that ADxMenu 2 menus will not work in Mac IE, Opera 6 and any other browser that doesn&amp;rsquo;t fully support :hover pseudo-element.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Major improvement&lt;/strong&gt;: this CSS finally solves the &lt;a href=&#34;https://aplus.rs/css/ie-phone-book/&#34;&gt;&amp;ldquo;phone-book&amp;rdquo; problem&lt;/a&gt; in IE/Win, and sub menus can be normally repositioned, not one over another.&lt;/p&gt;
&lt;h5 id=&#34;pure-css-menus&#34;&gt;Pure CSS menus&lt;/h5&gt;
&lt;p&gt;First rule is to include the behavior (with proper path, relative to the .css file).&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;body { behavior:url(&amp;quot;csshover.htc&amp;quot;); }
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Then we remove the default list rendering and reset all box properties to 0. List items are floated to the left and positioned relatively, to define new coo-system for their child elements (sub menus).&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu ul {

	margin: 0;

	padding: 0;

	border: 0;

	list-style-type: none;

}



#menu li {

	margin: 0;

	padding: 0;

	border: 0;

	display: block;

	float: left;

	position: relative;

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;A elements are transformed to blocks. For the sake of, and only for, IE/Mac, they are also floated to the left, using famous backslash-commented hack. All sub menus are absolutely positioned.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu a {

	float: left;/* */float: none;/*  */

	display: block;

}

#menu li ul {

	visibility: hidden;

	position: absolute;

	z-index: 10;

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The next part is crucial to avoid &amp;ldquo;phone-book&amp;rdquo; problem. Sub menu list items are pos:relative for anything but IE. This way, there are no new z-index &amp;ldquo;spaces&amp;rdquo; and sub menu will not go under the remaining items in the parent menu. Only when the sub menu is about to be displayed, its parent item is going pos:relative, allowing &amp;hellip;&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu li ul li {

	width: 100%;

	display: block;

	float: left;

	position: static;

}

html&amp;gt;body #menu li ul li {

	float: none;

	position: relative;

}

#menu li ul li:hover {

	position: relative;

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&amp;hellip;correct placement. Without the li:hover support, this is not possible. Peter deserves eternal gratitude for this.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu li ul li ul {

	top: 0;

	left: 100%;

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Unfortunately, there is no way to simulate the child selector, also needed for nested menus. Therefore, we need to cheat a little.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;div#menu li:hover ul, #menu li:hover li:hover ul,

#menu li:hover li:hover li:hover ul {

	visibility: visible;

}

#menu li:hover li ul, #menu li:hover li:hover li ul,

#menu li:hover li:hover li:hover li ul {

	visibility: hidden;

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;That first div is needed for IE5.x support. Last version of behavior should actually work without the actual node name specified. And it does in IE6. Also in some simple cases in IE5, but not in this. Strangely, adding just one node name solves the problem. Peter said to me that it must be some error in .htc, but I believe that it&amp;rsquo;s some IE5.x quirk.&lt;/p&gt;
&lt;p&gt;For advanced browsers, that understand child selector, use it instead of the code above. This part can actually be removed, but I deliberately included it to show the proper way how this should be done.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu ul#menuList li:hover &amp;gt; ul {

	visibility: visible;

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;That is all. This is enough to make the menus work. Rest of the styles is up to your CSS and designer skills. Take a look at &lt;a href=&#34;../examples/&#34;&gt;the examples&lt;/a&gt; I provided.&lt;/p&gt;
&lt;p&gt;Read the next ADxMenu entry to learn about the script that will reposition the menus if they go outside the visible window area. It also incorporates &lt;a href=&#34;https://aplus.rs/wch/wch-2/&#34;&gt;WCH2&lt;/a&gt; script which helps with &lt;a href=&#34;https://aplus.rs/wch/those-things-that-refuse-to-obey/&#34;&gt;yet another IE/Win problem&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Update (May 1st): After few questions in the comments, I realized that I haven&amp;rsquo;t explained the logic behind the IE simulation of child selector. So, here it goes.&lt;/p&gt;
&lt;h5 id=&#34;how-to-add-more-submenu-levels-for-ie&#34;&gt;How to add more submenu levels for IE&lt;/h5&gt;
&lt;p&gt;If you look at the &lt;a href=&#34;../examples/&#34;&gt;unstyled version&lt;/a&gt; of the list, you can see that, when particular item is hovered, we want the first nested list to appear, and all deeper nested lists to be hidden. This is possible with child selector - it will take all elements inside of the &lt;code&gt;li&lt;/code&gt; and fetch just first &lt;code&gt;ul&lt;/code&gt; it encounters:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu li:hover &amp;gt; ul {

	visibility: visible;

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;In example list, when mouse is over &lt;em&gt;Products&lt;/em&gt;, browser&amp;rsquo;s CSS engine will find that &lt;code&gt;li&lt;/code&gt; and then start to process all elements inside of it. It first finds &lt;code&gt;a&lt;/code&gt;, skips it, and then finds &lt;code&gt;ul&lt;/code&gt;, applies the style to it and stops.&lt;/p&gt;
&lt;p&gt;Since IE doesn&amp;rsquo;t support this, we need to simulate it. Look at this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu li:hover ul {

	visibility: visible;

}

#menu li:hover li ul {

	visibility: hidden;

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Look at the HTML code for the list and work it out down the nesting. &lt;code&gt;#menu&lt;/code&gt; starts it up and then goes to process all its children. It skips the &lt;code&gt;ul&lt;/code&gt; for the main menu, and then finds the Products list item. &lt;code&gt;li:hover ul&lt;/code&gt; means &amp;ldquo;find all UL elements inside of this LI and apply the style to all of them&amp;rdquo;. And thus not only Products submenu is visible, but also Categories and Hardware. So we need another rule to leave Products visible, and hide those that are nested deeper.&lt;/p&gt;
&lt;p&gt;The other rule has one more &lt;code&gt;li&lt;/code&gt; before the &lt;code&gt;ul&lt;/code&gt;. That means that browser will find all ULs nested inside each list item in the Products submenu and hide them.&lt;/p&gt;
&lt;p&gt;To be simple and clear: when you load the page, only main menu is shown. When you mouse over &lt;em&gt;Products&lt;/em&gt; item, first rule will show all possible submenus - for Products, Categories and Hardware. What we actually need is just Products submenu to appear. Second rule makes sure that Categories and Hardware submenus are hidden.&lt;/p&gt;
&lt;p&gt;For deeper levels, you need to repeat this rule pair and each time add one more &lt;code&gt;li:hover&lt;/code&gt; just after &lt;code&gt;#menu&lt;/code&gt;. Here is how it looks for one level down (&lt;em&gt;Categories&lt;/em&gt;).&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#menu &amp;lt;strong&amp;gt;li:hover&amp;lt;/strong&amp;gt; li:hover ul {

	visibility: visible;

}

#menu &amp;lt;strong&amp;gt;li:hover&amp;lt;/strong&amp;gt; li:hover li ul {

	visibility: hidden;

}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Since I have 3 submenus (main menu is not counted), in all .css files I have 3 pairs of rules.&lt;/p&gt;
&lt;p&gt;Or, to cut the long story short - number of &lt;code&gt;li:hover&lt;/code&gt; is identical to submenu level.&lt;/p&gt;</description>
    </item>
    
    <item>
      <title>Going cross-platform</title>
      <link>https://aplus.rs/2003/going-cross-platform/</link>
      <pubDate>Mon, 08 Dec 2003 11:30:09 +0000</pubDate>
      
      <guid>https://aplus.rs/2003/going-cross-platform/</guid>
      <description>&lt;p&gt;This revision of the script &amp;amp; style is rather small (hence the small version increment) but it adds important compatibility with Mac browsers. I&amp;rsquo;ve tested it on Mac OS 10.3, in Safari 1.1, IE 5.2.3, Firebird and Camino 0.7, Opera 6.03 and OmniWeb 4.5. Also tested on IE 5.1.7 on Mac OS 9 but very lightly as it appears that that one has identical behavior to 5.2.3. If you find differences, please let me know.&lt;/p&gt;
&lt;p&gt;CSS is slightly changed, and simplified in a way; more like streamlined, free from unneccesary style rules. I also returned WinXP style example - it needed change in IE-related script to work properly. Fixing this has side effect that item icons can be used again.&lt;/p&gt;
&lt;p&gt;I provided download links for each example menu style, so you can play around and reuse them.&lt;/p&gt;
&lt;h5 id=&#34;script-changes&#34;&gt;Script changes&lt;/h5&gt;
&lt;p&gt;Mac testing revealed some not very pleasant things. Safari had problem with the main style rule, repeated here (for full style review, checkout previous post):&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    	&lt;span class=&#34;k&#34;&gt;position&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;relative&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    	&lt;span class=&#34;k&#34;&gt;z-index&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;10000&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;In some cases it wrongly reports the distance from viewport top to the menu as &lt;code&gt;document.clientHeight&lt;/code&gt;(?!), which then screws up the check for off-screen placement. Since that style rule is only needed for IE/Win, I added &lt;code&gt;* html&lt;/code&gt; in front of it and now it works OK for IE and not causing problems for any other browser. To be sure that Safari does not break ever, I added this line of code to positioning part of the script:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;k&#34;&gt;if&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;ADXM_ua&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;indexOf&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;safari&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;!=&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;-&lt;/span&gt;&lt;span class=&#34;mi&#34;&gt;1&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt; &lt;span class=&#34;k&#34;&gt;return&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;OmniWeb uses the same engine as Safari (KHTML), but it has more problems - it reports item width as 0. :( To my surprise, Camino is doing the same (while Mac Firebird works great). So, similar lines as the one above are added at the begining of &lt;code&gt;ADXM_SetMenuPos()&lt;/code&gt; function.&lt;/p&gt;
&lt;p&gt;As you can see, I have returned the XP Luna style to the list of examples. To achieve the effect, I need &lt;code&gt;li:hover&lt;/code&gt;. Since IE/Win doesn&amp;rsquo;t support that, I added this to the script:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;nx&#34;&gt;oMenuLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;onmouseover&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    	&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;over&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;nx&#34;&gt;oMenuLI&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;onmouseout&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;kd&#34;&gt;function&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;()&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    	&lt;span class=&#34;k&#34;&gt;this&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;nx&#34;&gt;className&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;a href=&#34;http://www.alistapart.com/articles/dropdowns/&#34;&gt;Suckerfish drop-downs&lt;/a&gt; use the same stuff - class change is a very powerfull tool. It&amp;rsquo;s not very standard-oriented, but since we are using it simply to simulate standard behavior, it can pass.&lt;/p&gt;
&lt;p&gt;Now you simply need to style &lt;code&gt;li.over&lt;/code&gt; identically as &lt;code&gt;li:hover&lt;/code&gt; and you&amp;rsquo;re all set.&lt;/p&gt;
&lt;h5 id=&#34;style-changes&#34;&gt;Style changes&lt;/h5&gt;
&lt;p&gt;I have reworked the styles for Basic, Minitabs and WinXP example. They are now as simple as possible. Important change is the addition of this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;hover&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;ul&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    	&lt;span class=&#34;k&#34;&gt;left&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;30&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Because JS positioning is turned off in some cases, that means that submenus are placed right below parent item. In the vertical menu, that means that submenu will cover remaining items in the parent menu. This rule makes sure that submenu leaves some room, so user can select lower parent menu items. As one of the example shows, this rule has no effect in Camino 0.7. I figure this is a bug, so I&amp;rsquo;ll leave it be.&lt;/p&gt;
&lt;p&gt;And there&amp;rsquo;s also Opera 6. Whether on Mac or Windows, horizontal menu with &lt;code&gt;width:auto&lt;/code&gt; is going veeery wide. So this ugly bit of style rules is needed to fix that:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-css&#34; data-lang=&#34;css&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;c&#34;&gt;/* Fix for Opera 6 */&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;nt&#34;&gt;html&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;&amp;gt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;body&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt; &lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;mi&#34;&gt;67&lt;/span&gt;&lt;span class=&#34;kt&#34;&gt;px&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;c&#34;&gt;/* undo for CSS2-compliant browsers */&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    &lt;span class=&#34;nt&#34;&gt;head&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;nd&#34;&gt;first-child&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;+&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;body&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;#&lt;/span&gt;&lt;span class=&#34;nn&#34;&gt;menu&lt;/span&gt; &lt;span class=&#34;nt&#34;&gt;li&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt; &lt;span class=&#34;k&#34;&gt;width&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt; &lt;span class=&#34;kc&#34;&gt;auto&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;It gets worse in some cases, like in WinXP example where I needed to fix the submenu width (and widths of its LI elements). But, that&amp;rsquo;s the price of backward-compatibility. Personally, I would prefer to simply ditch Opera 6 support; unfortunatelly that involves server-side detection.&lt;/p&gt;
&lt;h5 id=&#34;yipi&#34;&gt;Yipi&lt;/h5&gt;
&lt;p&gt;OK, that&amp;rsquo;s it. All that&amp;rsquo;s left to do now is follow browser changes and fix what ever gets broken. I believe that bad times are behind us, and that future browsers will offer much better CSS2 support.&lt;/p&gt;
&lt;h5 id=&#34;update&#34;&gt;&lt;strong&gt;Update&lt;/strong&gt;&lt;/h5&gt;
&lt;p&gt;Small update for better browser support. After tests with Netscape 7.1 and PocketPC 2003 IE, I realized they don&amp;rsquo;t support menu re-positioning functions as well, so I added exit lines for them too. (Dec 10, 2003)&lt;/p&gt;</description>
    </item>
    
  </channel>
</rss>