Navigation - Colorado College

Section Links

Other Links


CC Site Navigation

To add a button to the left navigation bars, follow these steps:

  1. Open the leftnavData file you want to edit. All of the leftnavData files are located in the /include/leftnavData/ folder.

  2. Add this code to the spot you want the new button to appear on the sidemenu:
    idx= idx +1
    arDesc(idx)="BUTTON LABEL"
    arHref(idx)="/path/to/file"
    arSubItems(idx)=2         '*NUMBER OF ITEMS IN SUBMENU*
    '*INCLUDE THE CODE BELOW IF YOU HAVE A SUBMENU*
    if left_desc=arrDesc(idx) or left_id=arID(idx) then
    	left_select=idx
      	redim arHtmlID(arSubItems(idx))
        redim arHtmlHref(arSubItems(idx))
        redim arHtmlExtern(arSubItems(idx))
        redim arHtmlDesc(arSubItems(idx))
    	subidx= subidx+1
    '*REPEAT FOR EACH ITEM IN SUBMENU*
    	arHtmlID(subidx)="Some Link Here" 
        arHtmlHref(subidx)="/path_to_submenu_item/"
        arHtmlDesc(subidx)="CC 125th Anniversary"
        subidx= subidx+1
    '*END REPEAT*
    end if
    

  3. Save the data file and verify that the side bar looks as it should.