No announcement yet.

Category Drop Down Menu

  • Filter
  • Time
  • Show
Clear All
new posts

  • Category Drop Down Menu


    I'd like to add a drop down menu for my store categories (and subcategories). Does anyone have code they would like to share for this?

    Thanks in advance.

  • #2
    I'm sure you already know this, but a Google search for "drop down menu" will give you lots of Java Script to look at. While your at it, be sure to do some research about the use of drop-down menus and search engines - you will find many arguments as to whether or not they are good or bad. Then make your own decision!


    • #3
      There are lots of good, free CSS-only options for a fly-out menu (that are very cross-browser friendly with no need for Javascripting -- unless you want fancier effects or a delay before collapsing the menu).

      One way to approach this is to set up the category block to allow a nested, unordered list. Lists can be easily styled to show/hide the subcategory items. The trick is in getting the list tags in the right place in the category block on the frame.html page.

      Your category block would look like this:

      <div class="menu">
      <!--START: CATEGORIES-->
      <li><a href="view_category.asp?cat=CATID">CATEGORY</a>
      <li><a href="view_category.asp?cat=CATID">CATEGORY</a></li>
      <!--END: SUB_CATEGORY_FORMAT--></ul>
      <!--END: CATEGORIES-->
      <!--END: FRAME_CATEGORY-->

      With these elements wrapped in a DIV with a class assigned as an unordered list, the rest is writing the CSS. A great place to go for a nice selection of various fly-out and drop-down menus (not all are free) is CSS Play or Google for "free fly-out css menu".

      While this probably isn't the step-by-step how-to you wanted, these menus can take quite a bit of time to get just right. Even the pros don't get it pixel perfect the first time. :-)

      Hope this helps a bit....


      • #4
        Looks like the block can only be used once on the page.
        If I use it for main menu dropdown it stops working for side menu.