Event.observe(window, "load", init, false);

function init() {
	target1 = {success:"topicsImport"};
	target2 = {success:"serviceImport"};
	target3 = {success:"featureImport"};
	target4 = {success:"recruitImport"};
	url1 = "data/topics.dat";
	url2 = "data/service.dat";
	url3 = "data/feature.dat";
	url4 = "data/recruit.dat";
	options1 = {method:"get", onFailure:ajErr1};
	options2 = {method:"get", onFailure:ajErr2};
	options3 = {method:"get", onFailure:ajErr3};
	options4 = {method:"get", onFailure:ajErr4};

	new Ajax.Updater(target1, url1, options1);
	new Ajax.Updater(target2, url2, options2);
	new Ajax.Updater(target3, url3, options3);
	new Ajax.Updater(target4, url4, options4);
}

function ajErr1(req) {
	$("topicsImport").innerHTML = "error";
}
function ajErr2(req) {
	$("serviceImport").innerHTML = "error";
}
function ajErr3(req) {
	$("featureImport").innerHTML = "error";
}
function ajErr4(req) {
	$("recruitImport").innerHTML = "error";
}
