// JavaScript Document
function getUrlVars()
{
    var vars = [], hash;
    var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');
   for(var i = 0; i < hashes.length; i++)
    {
        hash = hashes[i].split('=');

        vars.push(hash[0]);
        vars[hash[0]] = hash[1];
    }

    return vars;

}
function getPage()
{
         
         var v=getUrlVars();
         var page = "p="+v["p"];
         $(document).ready(function(){
         $("#sidebar #menu ul li a").each(function(){

                 var it = $(this).attr("href");
                 if(it.slice(it.indexOf('?')+1) == page)
                 {
                 $(this).parent().parent().show();
                 }
         
         });
         });
         
}
function getAnchor()
{
		var str = window.location.href.slice(window.location.href.indexOf('#')+1);
		return str;
}
$(document).ready(function(){
$("#tcontent").hide();
$("#sliderout").hide();
$("#tcontent").fadeIn(2000);
$("#sliderout").slideDown(1500);

});

getPage();
						   /*
$("#sidebar #menu li a").click(function(){
			var url = $(this).attr("href").slice($(this).attr("href").indexOf("#")+1);
			if(url=="") url = getAnchor();
			switch(url)
			{
				case "home" : $("#content #lpage").html("hello");break;
				case "history" : $("#content #lpage").load("home.php");break;
			}
			
			
});
});  */

