Create A Forum - Support Forums

Support => Create a Forum Codes and Support => Topic started by: Arekay on February 09, 2011, 08:43:06 am

Title: [Code] Add Dropdown list to Menu Buttons
Post by: Arekay on February 09, 2011, 08:43:06 am
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:
Code: [Select]
<script type="text/javascript">
   /*Created by Arekay*/
                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>");

Relplace PLACE with which button you want:
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 (, look at the Help and Arcade tabs