// JavaScript Document
var image;
var gallery_id;
var galleryUrl;
var gallery_title;
var additional_info;
var imageUrl;

function getxml(){
    if (window.XMLHttpRequest){
        var ajaxResponse = new XMLHttpRequest();
    }else
    if(window.ActiveXObject){ // IE
        try{
            var ajaxResponse = new ActiveXObject("Msxml2.XMLHTTP");
        }catch(e){
            try {
                var ajaxResponse = new ActiveXObject("Microsoft.XMLHTTP");
            }catch(e){}
        };
    };
    if( !ajaxResponse ){
        return false;
    };
    ajaxResponse.open('GET', arguments[0], false);
    ajaxResponse.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
    ajaxResponse.send(null);
    if(ajaxResponse.status == 200){
        //return ajaxResponse.responseText;
				var result = ajaxResponse.responseText;
				var output = result.split("|");
				image = output[0];
				gallery_id = output[1];
				galleryUrl = output[5];
				gallery_title = output[3];
				additional_info = output[4];
				image_url = output[6];

    }else{
        return false;
    };
}; 

function request_get_data(){
//	var urlFile = "http://www.webxpercs.com/pep/frontend/peparazzi_slideshow_process.php";
	var urlFile = "http://www.pep.ph/peparazzi_slideshow_process_new.php";
	var xml = getxml(urlFile);

	return xml;
}

/*
function request_get_data(id, column){
//	var urlFile = "http://www.webxpercs.com/pep/frontend/peparazzi_slideshow_process.php";
	var urlFile = "http://www.pep.ph/peparazzi_slideshow_process.php";
	var lid = "?id="+id;
	var field = "&column="+column;
	var xml = getxml(urlFile+lid+field);

	return xml;
}
*/
