$(document).ready(function(){ 
    //Init menu
    $("#menu ul").superfish();
    //Popup for links on left column 
    if ($('.news a').length) {
        $(".news a,#shareThis a,#siteTips a,#siteTerminology a").click(function(){
            showPopup($(this).attr("href"));
            return false;
        });
    }
    //Popup for button on flash
    if ($('#flashText a').length) {
        var boolVal =  $("#boolVal").val();
        if(boolVal == 0){
            $("#flashText a").fancybox({
    			'width'				: '75%',
    			'height'			: '75%',
    			'autoScale'			: false,
    			'transitionIn'		: 'none',
    			'transitionOut'		: 'none',
    			'type'				: 'iframe'
    		});
        }
    }
}); 
function showPopup(url) {
    newwindow=window.open(url,'name','height=800,width=800,top=200,left=900,resizable,scrollbars');
    if (window.focus) {
        newwindow.focus();
    }
}
