Skip to content

[Code] Add Dropdown list to Menu Buttons

2945 Views 0 Replies

0 Members and 2 Guests are viewing this topic.

[Code] Add Dropdown list to Menu Buttons
on:
#1
This code will add a dropdown list to the menu buttons that don't already have one.



This code utilizes jQuery, please use the latest version found in this thread: http://support.createaforum.com/5/jquery-v1-8-update/
Footer:
Code: [Select]
<script type="text/javascript">
   /*Created by Arekay www.symtaxnet.tk*/
                if(document.getElementById("button_PLACE")!==null) $("li#button_PLACE").append("<ul><li><a href='LINK'><span>TITLE</span></a></li><li><a href='LINK'><span>TITLE</span></a></li>/*EXTRA*/</ul>");
</script>

Relplace PLACE with which button you want:
  • Home= home
  • Help= help
  • Search= search
  • Arcade= arcade
  • Logout= logout
  • Login= login
  • Register= register
Replace LINK with the link you want

Replace TITLE with the text that will show in the dropdown list

If you want more than two links, Replace /*EXTRA*/ with
Code: [Select]
<li><a href='LINK'><span>TITLE</span></a></li>
Preview at http://www.syntaxnet.tk/, look at the Help and Arcade tabs
Last Edit: August 12, 2012, 03:43:59 pm by xboi209