Jquery menus


Active member
I know this forum is php/mysql issues but figured maybe someone can point me in the right direction as jscript isn't my strong suit.

I'm trying to setup a vertical menu system for my front page. However I seem to be having some issues with it. When the site loads, it loads each div container when there should only be one that switches based on which button is pressed. The kicker is, if you press the menu buttons, the extra div containers disappear and the menus work fine. Here is the JS besides jquery

http://revenantgaming.com is the site.

  $('#sidemenu a').on('click', function(e){

    if($(this).hasClass('open')) {
      // do nothing because the link is already open
    } else {
      var oldcontent = $('#sidemenu a.open').attr('href');
      var newcontent = $(this).attr('href');
      $(oldcontent).fadeOut('fast', function(){
      $('#sidemenu a').removeClass('open');
Can provide other code as well.


Active member
Disregard, not sure if theres a better way, but I just used a counter and some CSS to hide anything after the first array record. Works perfect.