Menu Question!!

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • sassygray5
    New Member
    • Jul 2007
    • 5

    Menu Question!!

    my website www.horsespirit 5.com

    there are two menus, the one on the right I have a problem with.

    As you can see, on this menu I have affie rotation etc. Everything on this menu I am just manually coding on every page of the site. But, if I get a new affie, I would have to go through every page of the site and manually add the new button in.

    Is there a way to format the content for this menu in my stylesheet?

    Sorry, I hope my question makes sense. Thanks!!
  • jessnoonyes
    New Member
    • Jul 2007
    • 9

    #2
    Yep. Here's how:

    Make a new file, and call it "menu.js" then paste this in:


    <!-- Begin

    // NOTE: If you use a ' add a slash before it like this \'

    document.write( '<TABLE cellpadding="1" cellspacing="1" border="0" class="menu-table"><tr><td align="center"> ');

    // START LINKS COPY AND PASTE 2 LINES TO ADD A NEW BUTTON


    document.write( '<a href="index.htm l" class="menu">Ho me</a>');
    document.write( '</td><td align="center"> ');


    document.write( '<a href="contact.h tm" class="menu">Co ntact</a>');
    document.write( '</td><td align="center"> ');

    document.write( '</td></tr></table>');


    // End -->

    You'll have to format the table the way you need to menu to layout. This one I think is a horizontal menu.

    Then paste this in on every page where you need the menu:

    <script language="JavaS cript" type="text/javascript" src="menu.js"></script>

    Then anytime you need to change the menu you only have to alter menu.js to change it on all the pages. Time saver for sure.

    Comment

    • sassygray5
      New Member
      • Jul 2007
      • 5

      #3
      I have another question, sorry. Can I use javascript codes in this? For my banner rotation, it's a javascript code so can I put this in the menu?

      Comment

      Working...