﻿   
function GetNews()
{      
    xmlhttpPost_GetNews("/PageTemplates/FormProcessing.aspx?" + 
                "FormType=NewsArchive" +
                
                "&year=" + escape(document.getElementById('newsarchivedate').value));
      
    return false;
}

function xmlhttpPost_GetNews(strURL) 
{
    var xmlHttpReq = false;
    var self = this;
    // Mozilla/Safari
    if (window.XMLHttpRequest) {
        self.xmlHttpReq = new XMLHttpRequest();
    }
    // IE
    else if (window.ActiveXObject) {
        self.xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
    }
    self.xmlHttpReq.open('GET', strURL, true);
    self.xmlHttpReq.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
    self.xmlHttpReq.onreadystatechange = function() {
        if (self.xmlHttpReq.readyState == 4) {
            updatepage_GetNews(self.xmlHttpReq.responseText);
        }
    }
    self.xmlHttpReq.send(null);
}


function updatepage_GetNews(str)
{
    window.location = str;
}
