var Utils = {
		
	includeScript: function(script_url)
	{
		document.write('<' + 'script');
	    document.write(' language="javascript"');
	    document.write(' type="text/javascript"');
	    document.write(' src="' + script_url + '">');
	    document.write('</' + 'script' + '>');
	},

	isIE: function()
	{
		return (navigator.userAgent.indexOf('MSIE') != -1);
	},
  
	isIE6: function()
	{
	  return (navigator.userAgent.indexOf('MSIE 6') != -1);
	},

    isLoaded: function(name)
    {
    	var type;
        eval("type=typeof("+name+")");
    	if (type == "undefined")
        	return false;

        return true;
    },

	alert: function(msg)
    {
		alert(msg);
    },
    
    dump: function(obj)
    {
    	var out = '';
    	for (var i in obj)
    		out += i + ": " + obj[i] + "\n";
    	return out;
    },

    alert_error: function(e)
    {
    	if (this.isIE())
			this.alert(e.message);
        else
			this.alert(e);
    },

    setTimeout: function(callback, time)
    {
    	window.setTimeout(callback, time);
    }

};


