function rst (url, obj)

{
    if (window.XMLHttpRequest) { // Mozilla, Safari,...
   	    req = new XMLHttpRequest();
       	if (req.overrideMimeType) {
            req.overrideMimeType('text/xml');
            // See note below about this line
   	    }
    } else if (window.ActiveXObject) { // IE
        try {
   	        req = new ActiveXObject("Msxml2.XMLHTTP");
        } catch (e) {
            try {
   	            req = new ActiveXObject("Microsoft.XMLHTTP");
            } catch (e) {}
        }
  	};
	req.onreadystatechange = function() { alertContents(req, obj); };
	req.open('GET', url, true);

	req.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
   	req.send('location=' + window.location);
}


function alertContents(req, obj) {

        if (req.readyState == 4) {
            if (req.status == 200) {
                parseView(req, obj);
            }
        }

}

function parseView (req, obj)
{
	html = req.responseText;
//	objs = html.match(/<!--\s*obj\s*\=(.*?)\s*-->/i);
//    obj = objs[1];
//alert(obj);
	if (obj != 'nil') {
//    alert(obj);
		document.getElementById(obj).innerHTML = html;
    }
}
