function getinfo(id) {
   
        
            // Set up the request
			if (window.XMLHttpRequest){

          		// If IE7, Mozilla, Safari, etc: Use native object
          		var xmlhttp = new XMLHttpRequest()

			}
			else
			{

         		 // ...otherwise, use the ActiveX control for IE5.x and IE6
          		var xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
          	}
            xmlhttp.open('POST', '../../../mycheck.php?row='+id, true);
            
            // The callback function
            xmlhttp.onreadystatechange = function() {
                if (xmlhttp.readyState == 4) {
                    if (xmlhttp.status == 200) {
                        var title = xmlhttp.responseXML.getElementsByTagName('title')[0].firstChild.data;
                        var info = xmlhttp.responseXML.getElementsByTagName('info')[0].firstChild.data;
                        var desc = xmlhttp.responseXML.getElementsByTagName('desc')[0].firstChild.data;
                        var cost = xmlhttp.responseXML.getElementsByTagName('cost')[0].firstChild.data;
						var ncost = xmlhttp.responseXML.getElementsByTagName('ncost')[0].firstChild.data;
                        var month = xmlhttp.responseXML.getElementsByTagName('month')[0].firstChild.data;
                        var day = xmlhttp.responseXML.getElementsByTagName('day')[0].firstChild.data;
                        var year = xmlhttp.responseXML.getElementsByTagName('year')[0].firstChild.data;
                        var rsvp = xmlhttp.responseXML.getElementsByTagName('rsvp')[0].firstChild.data;
                        if(xmlhttp.responseXML.getElementsByTagName('fileone')[0].firstChild != null)
                        {
                        	var file1 = xmlhttp.responseXML.getElementsByTagName('fileone')[0].firstChild.data;
                        }
                        if(xmlhttp.responseXML.getElementsByTagName('filetwo')[0].firstChild != null)
                        {
                        	var file2 = xmlhttp.responseXML.getElementsByTagName('filetwo')[0].firstChild.data;
                        }
                        if(xmlhttp.responseXML.getElementsByTagName('filethree')[0].firstChild != null)
                        {
                        	var file3 = xmlhttp.responseXML.getElementsByTagName('filethree')[0].firstChild.data;
                        }
                        if(xmlhttp.responseXML.getElementsByTagName('linkTitle')[0].firstChild != null)
                        {
                        	var link = xmlhttp.responseXML.getElementsByTagName('link')[0].firstChild.data;
                        	var linkTitle = xmlhttp.responseXML.getElementsByTagName('linkTitle')[0].firstChild.data;
                        }
                        var str = "<h3 style='margin-bottom:0px;margin-top:0px;'>"+title+"</h3>";
                        str += "<p style='margin-top:0px;font-style:italic;width:100%;'>"+desc+"</p>";
                        str += "<p style='width:100%;'>Date: "+month+"/"+day+"/"+year+"</p>";
                        str += "<p style='width:100%;'>Member Cost: "+cost+"<br/>";
                        str += "Non-Member Cost: "+ncost+"</p>";
                        str += "<p style='width:100%;'>"+info+"</p>";
                        if(link)
                        {
                        	str += "<p style='width:100%;'><a href='"+link+"'>"+linkTitle+"</a></p>";
                        }
						if(rsvp == 1)
						{
							str += "<p style='width:100%;'><a href='mailto:info@exploitschamber.com?subject="+title+"'>RSVP</a><br/>";
						}
                        if(file1 != "" && file1 != null)
                        {
                        	var file = file1.split("-");
                        	str += "<p style='width:100%;'>Attached File: <a href='http://exploitschamber.com/download.php?f="+file[1]+"&e="+file[0]+"'>Download</a></p>";
                        }
                        if(file2 != "" && file2 != null)
                        {
                        	var file = file2.split("-");
                        	str += "<p style='width:100%;'>Attached File: <a href='http://exploitschamber.com/download.php?f="+file[1]+"&e="+file[0]+"'>Download</a></p>";
                        }
                        if(file3 != "" && file3 != null)
                        {
                        	var file = file3.split("-");
                        	str += "<p style='width:100%;'>Attached File: <a href='http://exploitschamber.com/download.php?f="+file[1]+"&e="+file[0]+"'>Download</a></p>";
                        }
                        document.getElementById("calendar_content").innerHTML=str;
                    }
                }
            }
            
            // Send the POST request
            xmlhttp.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
            xmlhttp.send('row=' + id);
} 

function vote(answer)
{
			// Set up the request
			if (window.XMLHttpRequest){

          		// If IE7, Mozilla, Safari, etc: Use native object
          		var xmlhttp = new XMLHttpRequest();

			}
			else
			{

         		 // ...otherwise, use the ActiveX control for IE5.x and IE6
          		var xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
          	}
            xmlhttp.open('POST', 'vote.php', true);
            // Send the POST request
            xmlhttp.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
            xmlhttp.send('answer=' + answer);
            // The callback function
            xmlhttp.onreadystatechange = function() {
                if (xmlhttp.readyState == 4) {
                    if (xmlhttp.status == 200) {
                     
										if (xmlhttp.responseXML.xml == "" ) {
											var result = (new DOMParser()).parseFromString(xmlhttp.responseText, "text/xml");
										} else {
												var result = xmlhttp.responseXML;
										}
                      var title = result.getElementsByTagName('title')[0].firstChild.data;
                       var lbody = document.getElementById("lbody");
                       if( title == 'success' )
                       {
													lbody.innerHTML = result.getElementsByTagName('pollstatus')[0].firstChild.data;
												}
                      // lbody.innerHTML = "<p>Thank you for voting.</p>";
                    }
                }
            }
}
