 function checkAndRedirect(url,url2)
            {
               
                var lastUrl=window.location.href;
                if(lastUrl.split('?')[1]!=null)
                {
                    
                    window.location=url2+"?"+lastUrl.split('?')[1];
                }
                else
                {
                    
                    window.location=url;
                }
                
                
              
            }

function SubMenu(menu, status) {
        for(var n=0; n<menu.childNodes.length; n++) {
               if(menu.childNodes[n].nodeName.toUpperCase()=='A') {
                       if(status) {
                               menu.childNodes[n].className = 'active';
                       } else {
                               menu.childNodes[n].className = '';
                       }
               }
        }
        for(var n=0; n<menu.childNodes.length; n++) {
               if(menu.childNodes[n].nodeName.toUpperCase()=='UL') {
                       if(status) {
                               menu.childNodes[n].style.display = 'block';
                       } else {
                               menu.childNodes[n].style.display = 'none';
                       }
               }
        }
    }
