Loading ...
Sorry, an error occurred while loading the content.

Trouble with a Cascading Menu Script

Expand Messages
  • jonaloti
    Hi, I am attempting to add a cascading menu to a website. Here s what I did: I put these files into the public_HTML folder: - a JavaScript file, HMenu.js - a
    Message 1 of 1 , Sep 8 9:17 AM
    • 0 Attachment
      Hi,
      I am attempting to add a cascading menu to a website.
      Here's what I did:
      I put these files into the public_HTML folder:
      - a JavaScript file, HMenu.js
      - a stylesheet file, HMenu.css
      - a HTML menu file, menu.html

      When the menu is loaded and displayed on a web page, it just displays every menu and item in a list straight down the page...
      This is my first "js" attempt.

      This is the short webpage I used to try and display the menu properly. Everything b4 the </head> was inserted automatically by the HTML editor. I used a href to activate the menu:

      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <html xmlns="http://www.w3.org/1999/xhtml">
      <head>
      <title>Your page</title>
      <script language="JavaScript" src="HMenu.js"></script>
      <link rel="stylesheet" href="HMenu.css" />
      </head>
      <body onload="initMenu()"><a href="menu.html" menu=menu1>Main Menu</a>
      </body>
      </html>


      This is the beginning of the menu I used from a tutorial webpage:

      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <html xmlns="http://www.w3.org/1999/xhtml">
      <head>
      <title>Your page</title>
      <script language="JavaScript" src="HMenu.js"></script>
      <link rel="stylesheet" href="HMenu.css" />
      </head>
      <body onload="initMenu()">
      <div id="menuContainer">
      <div class="menu" id="menu1">
      <div class="menuItem" id="subMenu1_1"><a href="http://brucemorris.com">Bruce Morris</a></div>
      <div class="menu" id="menu1_1">
      <div class="menuItem" id="menuItem1_1_1"><a href="columns/pointy-haired_boss.html">The Dotcom Pointy-haired Boss Syndrome</a></div>
      <div class="menuItem" id="menuItem1_1_2"><a href="columns/napster_pull_your_pants_up.html">Hey Napster Fans...</a></div>

      ... it continues with more menu items.

      They delivered the info in pieces and I think I may have assembled it out of order? Or, maybe I'm totally wrong, but it looked simple?

      Any words of wisdom is great. I am new at design... point me, please.

      Thanks
    Your message has been successfully submitted and would be delivered to recipients shortly.