function xajax_processContactForm() {
	xajax.call("processContactForm",arguments,1);
}
function xajax_processRegistrationForm(){
	xajax.call("processRegistrationForm",arguments,1);
}
function xajax_processOrderForm(){
	xajax.call("processOrderForm",arguments,1);
}
function xajax_orderSampleBagsForm(){
	xajax.call("orderSampleBagsForm",arguments,1);
}
function xajax_order8StripsForm(){
	xajax.call("order8StripsForm",arguments,1);
}
function xajax_storeOrderForm(){
	xajax.call("storeOrderForm",arguments,1);
}
function xajax_processLogin() {
	xajax.call("processLogin",arguments,1);
}
function xajax_processLogout() {
	xajax.call("processLogout",arguments,1);
}
function xajax_send_password() {
	xajax.call("send_password",arguments,1);
}
function showTable(id,cnt) {
	var outer=xajax.$(id+'_outer');
	var table=xajax.$(id);
	var body=xajax.$(id+'_body');
	for (var i=0; i<body.rows.length; i++) body.rows[i].style.display= (i<cnt) ? '' : 'none';
	if (table.offsetHeight >400) {
		outer.style.height=400+'px';
		outer.style.overflow='scroll';
	} else {
		outer.style.height=table.offsetHeight+'px';
		outer.style.overflow='';
	}
}
function checkForm(frm) {
	var e = frm.elements;
	var msg = '';
	var chk = '';
	var focusfld = '';
	var i;
	for(i=0;i<e.length;i++) e[i].className = e[i].className.replace('mandatory','');
	for(i=0;i<e.length;i++) {
		if (chk = e[i].getAttribute('inpchk')) {
			var el=e[i];
			if (chk == 'notempty') {
				var value=el.value;
				if (el.type=='radio') {
					var rcol=e[el.name];
					value=false;
					for(ii=0;!value && ii<rcol.length;ii++) value=rcol[ii].checked;
					if (!value) for(ii=0;ii<rcol.length;ii++) rcol[ii].className += ' mandatory';
				} else {
					if (value == '') {
						value=false;
						el.className += ' mandatory';
					}
				}
				if (!value) {
					if (focusfld == '') focusfld = i;
					msg += el.getAttribute('chkmsg')+"\n";
				}
			}
		}
	}
	if (msg) {
		alert(msg);
		e[focusfld].scrollIntoView(false);
		e[focusfld].focus();
		return false;
	}
	e['checksum'].setAttribute("value",location.hostname);
	return true;
}
function prtwnd() {
	var url=location.href;
	if (url.substr(-1)=='/') url+='print/';
	else url+='/print/';
	var pwnd = window.open(url,"prtwnd");
	if (!pwnd) alert('Het is niet mogelijk om een printwindow te openen. Heeft u mogelijk popup-windows geblokkeerd?');
}