// JavaScript ajax.js

/* This page creates and ajax request */

	// Initialize the object
	var ajax = false;
	
	// Create the object
	// Check for support object type
	if (window.XMLHttpRequest) {
		
		// IE7, Mozilla, Safari, Opera
		ajax = new XMLHttpRequest();
		
	} else if (window.ActiveXObject) {
		
		// Older IE browsers
		// Create type Msxml2.XMLHTTP if possible
		try {
			
			ajax = new ActiveXObject("Msxml2.XMLHTTP");
			
		} catch (e1) {
			
			try {
				
				ajax = new ActiveXObject("Microsoft.XMLHTTP");
				
			} catch (e2) { }
			
		}
	
	}
	
	// Send an alert if the object was not created
	if (!ajax) {
		alert('Some page functionality is unavailable.');
	}
	
