var query_regx = /^[A-Za-z0-9;.\ \+&_"'\(\)-]*$/;

function get_radio(radio) {
	for (i=0; i<radio.length; i++) {
		if (radio[i].checked) {
			return radio[i].value;
		}
	}
	return "";
}

function do_query(q, h_category) {
	if ( query_regx.match(q) ) {
		if(h_category == "womens-2ocg70" || h_category == "mens-turzve" || h_category == "kids-ikyphw") {
			document.location='/'+encodeURIComponent(q)+'/c/'+h_category;
		}
		else {
			document.location='/'+encodeURIComponent(q);
		}
	}
	else
		document.location='/';
}
