// JavaScript Document
//
// Adapted by Andy Frazier/ Reliable Softworks
// from "the wall" sample iPhone application
// http://www.briandunning.com/iphone
// by Brian Dunning
//

function getHTTPObject() {
    if (typeof XMLHttpRequest != 'undefined') {
        return new XMLHttpRequest();
    }
    try {
        return new ActiveXObject("Msxml2.XMLHTTP");
    } catch (e) {
        try {
            return new ActiveXObject("Microsoft.XMLHTTP");
        } catch (e) {}
    }
    return false;
}

function content(page) {
	var http = getHTTPObject();
	http.open("get", "library/" + page + ".php", true);
	http.onreadystatechange = function() {
		if (http.readyState == 4) {
			document.getElementById('content').innerHTML = http.responseText;
		}
	}
	http.send(null);
}
