    function jsclear(e,str) {
        if ( e.value == str ) {
            e.value = '';
        }
    }

    function jsreplace(e,str) {
        
        if ( e.value == '' ) {
            e.value = str;
        }
        
    }

    function validateNSBox(frm) {
    
        // ERR MSG
        var msg = '';
    
        // PULL VALUES
        fn = frm.elements['fn'].value;
        em = frm.elements['em'].value;
    
        // FIRST
        if ( fn == '' || fn == 'Name' ) {
            msg = msg + "Please Enter Your Name\n";
        }
    
        // EMAIL
        if ( !jsValidateEmailAddress(em) ) {
            msg = msg + "Please Enter Valid Email\n";
        }
    
        /// ALERT?
        if ( msg != '' ) {
            alert(msg);
            return false;
        }
    
        /// URL STR
        url  = "newsletter.php?em="+escape(em)+"&fn="+escape(fn);
    
        /// OPEN WINDOW
        em_window = window.open(url,'','height=200,width=300,toolbar=0,statusbar=0');
    
        return true;
    
    }



function popUp(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=380,height=400');");
}
function GetMyCookieVal(offset) { 
    var endstr = document.cookie.indexOf ( ";", offset ) ; 
    if ( endstr == -1 ) endstr = document.cookie.length ; 
    return unescape(document.cookie.substring(offset, endstr) ) ; 
}
 function GetMyCookie(name) { 
    var arg = name + "=" ; 
    var alen = arg.length ; 
    var i = 0 ; 
    var clen = document.cookie.length ; 
 
    while (i < clen) { 
        var j = i + alen 
        if ( document.cookie.substring(i,j) == arg ) { 
            var v =  GetMyCookieVal (j) ; 
            return v ; 
        } 
        i = document.cookie.indexOf (" ", i) + 1 ; 
        if ( i == 0 ) break ;  
	} return null ; 
}  

function read_querystring() 
   { 
   var a_out = new Object(); 
   //a_out[0] = "";
   var s_loc = String(location.href); 
 	//alert(s_loc);
   if(s_loc.indexOf('?')>0) 
     { 
     var p; 
     var s_query = s_loc.substr(s_loc.indexOf('?')+1); 
     var a_query = s_query ? s_query.split('&') : new Array(); 
 
     for(var i=0; i<a_query.length; i++) 
       { 
       p = a_query[i].split('='); 
       a_out[p[0]] = p[1].replace(/\+/g, ' '); 
     } 
   } 
    return a_out; 
 
}



function openpopuptos()
	{
	var popurl="tos.php"
	winpops=window.open(popurl,"","width=600,height=500,scrollbars,")
	}


// Start alli functions

    
    	function hideItems()
    	{
    		document.getElementById('burger').style.display="none";
    		document.getElementById('burgerAnchor').className = "";
			document.getElementById('chicken').style.display="none";
			document.getElementById('chickenAnchor').className = "";
			document.getElementById('lasagna').style.display="none";
			document.getElementById('lasagnaAnchor').className = "";
			document.getElementById('chinese').style.display="none";
			document.getElementById('chineseAnchor').className = "";

    	}
    	
	    function showItem(divid) 
		{
			document.getElementById(divid).style.display="block";
			var anchorName = divid + "Anchor";
			if (document.getElementById(anchorName) != null)
			{
				document.getElementById(anchorName).className = "active";
				
			}
			
		}

		function OpenPopUp(URL,title, width, height)
			{
				 <!-- Relace baseURL to http://www.myalli.com/ -->
				var baseURL = 'http://www.myalli.com/';
				
				
				if (width == null)
				{
					width = 670;
				}
				if (height == null)
				{
					height = 440;
				}
				
				window.open(baseURL+ URL, title, 'scrollbars,resizable=no,width=' + width + ',height=' + height + ',left=25,top=25');
			}    
      


// End alli functions

