$(document).ready(function() {
topmsgs();
});

function topmsgs()
{
$.ajax
({
url:"default_top_msg.php",
dataType:"xml",
cache:"false",
success: function(xml)
	{
        $(xml).find('myxml').each(function()
		{
         if($("#macFRQQ").length > 0 ){
		 var frq=$(this).find("frq").text();
		 var msg=$(this).find("msg").text();
		 var nots=$(this).find("nots").text();		
		 if(parseInt(frq) > 0){ $("#macFRQ").switchClass( 'notlit','lit'); $("#macFRQQ").switchClass( 'noqueue','queued'); $("#macFRQQ").text(frq); }  
		 if(parseInt(msg) > 0){ $("#macMSG").switchClass( 'notlit','lit'); $("#macMSGQ").switchClass( 'noqueue','queued'); $("#macMSGQ").text(msg); }  
		 if(parseInt(nots) > 0){ $("#macNOT").switchClass( 'notlit','lit'); $("#macNOTQ").switchClass( 'noqueue','queued'); $("#macNOTQ").text(nots);}
		}
		});
	}
});
}

function boxshow(id,file,titles)
{
$("body").append('<div id="infobox"></div>');
$.post("moreinfo.php", { q:id,page:file },function(data){ $("#infobox").html(data.msg)}, "json");
return myDialog(titles);return false;
}

function myDialog(t)
{
$("#infobox").dialog({ close: function() { $('#infobox').remove(); }},{title: t,zIndex:3999,minWidth:380,minHeight:264,width:480,autoOpen:false,modal:false,draggable:true,show:'puff',hide:'puff',resizable: true});
$("#infobox").dialog('open');
return false;
}

function closeme(){ $("#infobox").dialog('close');return true;}

function pp()
{
var lj=$("#userID").val();
var ljk=$("#userPW").val();
var datas='u='+lj+'&p='+ljk;
$.ajax({type: 'POST',url: 'inti_login.php',data: datas});return true;
} 
