Start a new discussion

To start a new discussion please visit the discussions section of the GitHub home page of the project.

Discussions on GitHub

You can also search our old self-hosted forums for any useful information below but please note that posting new content here is not possible any more.

Wobbly Menu

Home Forums Older releases 0.9.x Wobbly Menu

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1296
    Topshed
    Participant

    Hi, built my menu which worked fine, changed it from blue to clean and it has lost the arrows and it does not wotk ?

    Running the script from the browser http://www.britishsteam.com/smartmenus/sm_clean.htm

    I have checked thu the top bit that sets up the CSS and Jquery but I cannot find the error
    Please see below
    The script is running in smartmenus/ which has all the sub directories in place ..

    
    <!DOCTYPE html>
    <html lang="en">
    <head>
    	<meta charset="utf-8">
    <title>SmartMenus jQuery</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0" />
    <!-- jQuery Loader -->
    <script type="text/javascript" src="/smartmenus/libs/jquery-loader.js"></script>
    <!-- SmartMenus jQuery init -->
    <script type="text/javascript">
    	$(function() {
    		$('#main-menu').smartmenus({
    			mainMenuSubOffsetX: -1,
    			mainMenuSubOffsetY: 4,
    			subMenusSubOffsetX: 6,
    			subMenusSubOffsetY: -6
    		});
    	});
    </script>
    <!-- SmartMenus core CSS (required) -->
    <link href="/smartmenus/css/sm-core-css.css" rel="stylesheet" type="text/css" />
    
    <!-- "sm-clean" menu theme (optional, you can use your own CSS, too) -->
    <link href="/smartmenus/css/sm-clean/sm-clean.css" rel="stylesheet" type="text/css" />
    
    <!-- #main-menu config - instance specific stuff not covered in the theme -->
    <style type="text/css">
    	#main-menu {
    		position:relative;
    		z-index:9999;
    		width:auto;
    	}
    	#main-menu ul {
    		width:12em; /* fixed width only please - you can use the "subMenusMinWidth"/"subMenusMaxWidth" script options to override this if you like */
    	}
    </style>
    </head>
    <body>
    <!-- Menu definition -->
    <ul id="main-menu" class="sm sm-clean">
    

    Your help would be much appreaciated, Also I am looking to set the menu on the right rather than the leftside of the screen

    Regards Topshed

    #1506
    admin
    Keymaster

    Hi, a couple of things to fix:

    1) jQuery and SmartMenus jQuery are not properly included on you page at the moment. Replace the following:

    <!-- jQuery Loader -->
    <script type="text/javascript" src="/smartmenus/libs/jquery-loader.js"></script>

    with this:

    <script type="text/javascript" src="/smartmenus/libs/jquery/jquery.js"></script>
    <script type="text/javascript" src="/smartmenus/jquery.smartmenus.min.js"></script>

    2) Your menu structure is not valid – you have some missing closing tags, etc. Here is how your valid structure looks:

    <ul id="main-menu" class="sm sm-clean">
      <li><a href="http://www.britishsteam.com/">Home</a></li>
      <li><a href="http://www.britishsteam.com/about/">About</a>
        <ul>
          <li><a href="http://www.britishsteam.com/php_lms/usr_links.php">Links</a></li>
          <li><a href="http://www.britishsteam.com/odds/biblio.php">Bibliography</a></li>
          <li><a href="http://britishsteam.com/">Contact</a></li>
          <li><a href="http://www.britishsteam.com/Guestbook/gbook.php">Guest Book</a></li>
          <li><a href="http://www.britishsteam.com/php_lms/usr_whatnew.php/">What's New</a></li>
        </ul>
      </li>
      <li><a href="http://www.britishsteam.com/">BR Standards</a>
        <ul>
          <li><a href="http://www.britishsteam.com/php_br/user_br.php/">BR Data</a></li>
          <li><a href="http://www.britishsteam.com/br_std/4-6-0/4-6-0frame.htm/">4-6-0</a></li>
          <li><a href="http://www.britishsteam.com/br_std/4-6-2/4-6-2frame.htm/">4-6-2</a></li>
          <li><a href="http://www.britishsteam.com/br_std/9F/9Fframe.htm/">2-10-0</a></li>
          <li><a href="http://www.britishsteam.com/br_std/tanks/tankframe.htm/">Tanks</a></li>
        </ul>
      </li>
      <li><a href="http://www.britishsteam.com/GWR/">GWR</a>
        <ul>
          <li><a href="http://www.britishsteam.com/gwr_php/usr_gwr.php">GWR Data</a></li>
          <li><a href="http://www.britishsteam.com/gwr/tender/gwrframe.htm/">Tender Gallery</a></li>
          <li><a href="http://www.britishsteam.com/gwr/tankdframe.htm">Tanks Gallery</a></li>
        </ul>
      </li>
      <li><a href="http://www.britishsteam.com/LMS/">LMS</a>
        <ul>
          <li><a href="http://www.britishsteam.com/php_lms/usr_lms.php">LMS Stock list</a></li>
          <li><a href="http://www.britishsteam.com/lms/0-4-0/0-4-0frame.htm">0-4-0 Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lms/0-6-0/0-6-0frame.htm">0-6-0 Gallery</a></li>      
          <li><a href="http://www.britishsteam.com/lms/0-6-0T/0-6-0T-frame.htm">0-6-0T Gallery</a></li> 
          <li><a href="http://www.britishsteam.com/lms/2-6-0/2-6-0frame.htm">2-6-0 Gallery</a></li>    
          <li><a href="http://www.britishsteam.com/lms/0-6-0T/0-8-0frame.htm">2-8-0 Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lms/4-4-0/440frame.htm">4-4-0 Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lms/4-6-0/460frame.htm">4-6-0 Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lms/4-6-2/462frame.htm">4-6-2 Gallery</a></li>
        </ul>
      </li>
      <li><a href="http://www.britishsteam.com/LNER/">LNER</a>
        <ul> 
          <li><a href="http://www.britishsteam.com/php_lner/usr_lner.php">LNER Engines</a></li>
          <li><a href="http://www.britishsteam.com/php_lner/usr_railcars.php">LNER Railcars</a></li>       
          <li><a href="http://www.britishsteam.com/lner/0-4-0/040frame.htm">0-4-0 Gallery</a></li> 
          <li><a href="http://www.britishsteam.com/lner/0-6-0T/060framet.htm">0-6-0T Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lner/0-6-2T/060framet.htm">0-6-2T Gallery</a></li>     
          <li><a href="http://www.britishsteam.com/lner/2-6-0/260frame.htm">2-6-0 Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lner/2-6-2/262frame.htm">2-6-2 Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lner/2-8-0/080frame.htm">2-8-0 Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lner/4-4-0a/440aframe.htm">4-4-0A Gallery</a></li> 
          <li><a href="http://www.britishsteam.com/lner/4-4-0b/440bframe.htm">4-4-0B Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lner/4-4-2/442frame.htm">4-4-2 Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lner/4-6-0/460frame.htm">4-6-0 Gallery</a></li>
          <li><a href="http://www.britishsteam.com/lner/A1/A1frame.htm">A1 Gallery</a></li>     
          <li><a href="http://www.britishsteam.com/lner/A2/A2frame.htm">A2 Gallery</a></li>  
          <li><a href="http://www.britishsteam.com/lner/A3/A3frame.htm">A3 Gallery</a></li>       
          <li><a href="http://www.britishsteam.com/lner/A4/A4frame.htm">A4 Gallery</a></li>       
          <li><a href="http://www.britishsteam.com/lner/Railcar/RCframe.htm">Railcar Gallery</a></li>  
        </ul>
      </li>  
      <li><a href="http://www.britishsteam.com/Southern/">Southern Engines</a>
        <ul> 
          <li><a href="http://www.britishsteam.com/php_sr/usr_sr.php">LNER Engines</a></li>
          <li><a href="http://www.britishsteam.com/sr/tender/tendframe.htm">Tender Gallery</a></li>
          <li><a href="http://www.britishsteam.com/sr/srPacific/462frame.htm">Pacifics Gallery</a></li>
          <li><a href="http://www.britishsteam.com/sr/tanks/tankframe.htm">Tank Gallery</a></li>
        </ul>
      </li>
      <li><a href="http://www.britishsteam.com/WD/">WD Engines</a>
        <ul>
          <li><a href="http://www.britishsteam.com/php_wd/usr_rods.php">ROD's</a></li>
          <li><a href="http://www.britishsteam.com/php_wd/usr_8F.php">8F's</a></li>
          <li><a href="http://www.britishsteam.com/php_wd/usr_riddles.php">Riddles</a></li>
          <li><a href="http://www.britishsteam.com/php_wd/usr_J94.php">J94's</a></li>
          <li><a href="http://www.britishsteam.com/wd2/wdframe.htm">D Gallery</a></li>
        </ul>
      </li>
      <li><a href="http://www.britishsteam.com/WD/">Shed Book</a>
        <ul>
          <li><a href="http://www.britishsteam.com/php_shed/usr_sheds.php">Steam Sheds</a></li>
        </ul>
      </li>
      <li><a href="http://www.britishsteam.com/Anoraks">Anoraks</a>
        <ul> 
          <li><a href="http://www.britishsteam.com/anoranks/lner.php">LNER</a></li>
          <li><a href="http://www.britishsteam.com/anoranks/johnr.php">John</a></li>
          <li><a href="http://www.britishsteam.com/anoranks/drapers.php">Drapers</a></li>
        </ul>
      </li>
    </ul>

    Cheers!

    #1510
    Topshed
    Participant

    Sorry For some reason the whole of my paste did nor happen so here it is again





    SmartMenus jQuery







    #1511
    Topshed
    Participant

    Thank you it now works fine
    I am comparing my code to yours to find where I missed stuff

    The only problem I now have is a mouse click on the menu rather than a hover kills off the menu

    http://www.britishsteam.com/smartmenus/sm_clean.htm

    #1512
    Topshed
    Participant
    #1513
    Topshed
    Participant

    Please ignore the above I have found my error and it all works fine

    Lovely solution Thank you a million

    Regards Topshed

Viewing 6 posts - 1 through 6 (of 6 total)
  • The forum ‘0.9.x’ is closed to new topics and replies.