$(document).ready(function() {	/* loading */	$().ajaxStart(function() {		$('.loading').show();	}).ajaxStop(function() {		$('.loading').hide();	});/* modalboxselect all the a tag with name equal to modal */$('a[name=modal]').click(function(e) {/* Cancel the link behavior */e.preventDefault();/* Get the A tag */var id = $(this).attr('href');/* Get the screen height and width */ var maskHeight = $(document).height(); var maskWidth = $(window).width();var myH = $(window).height(); $('#mask').css({'width':maskWidth,'height':maskHeight}); $('.window').css({'max-width':maskWidth,'max-height':maskHeight}); $('.TxT').css({'max-width':maskWidth,'max-height':myH});/* transition effect		 */$('#mask').fadeIn(1000);	$('#mask').fadeTo("slow",0.8);	/* Get the window height and width */var winH = $(window).height(); var winW = $(window).width();/*  Set the popup window to center */$(id).css('top',  winH/0-$(id).height()/0); $(id).css('left', winW/2-$(id).width()/2);/* transition effect */$(id).fadeIn(1000); });/* if close button is clicked */$('.window .close').click(function (e) {/* Cancel the link behavior */e.preventDefault();$('#mask').hide();$('.window').hide();});		/* if mask is clicked */$('#mask').click(function () {$(this).hide();$('.window').hide();});			/* dropdown menu */    $('#ngedown li').hover(        function () {/*             show its submenu */            $('ul', this).slideDown(700);         },        function () {/*             hide its submenu */            $('ul', this).fadeOut(900);                }    );	});
