function isInsiteSearchForm(form) {
	var keyword = form.keyword;
	var value = keyword.value;
	var errMsg = "Please put in a word and push a Search button";
	if(form.name == JLJS_InsiteSearch.INSITE_SEARCH_FORM) {
		if (!value || (value.match(/[\w| | ]/) && value.length == 1 ||value == JLJS_InsiteSearch.initValue)) {
			alert(errMsg);
			keyword.value = '';
			JLJS.classAttr.add(keyword, JLJS_InsiteSearch.CLASS_TXBLA);
			keyword.focus();
			return false;
		} else {
			return true;
		}

	}else{
		if (!value || (value.match(/[\w| | ]/) && value.length == 1)) {
			alert(errMsg);
			keyword.focus();
			return false;
		} else {
			return true;
		}
	}
}
function JLJS_InsiteSearchKeywordEvent() {
	this.initValue = 'Search jal.co.jp';
	this.CLASS_TXBLA = 'txBla';
	this.INSITE_SEARCH_FORM ="InsiteSearchForm"
}
JLJS_InsiteSearchKeywordEvent.prototype = {
	onload : function(form) {
		var keywordElem = form.keyword;
		JLJS_InsiteSearch.onblur(keywordElem);
		keywordElem.blur();
	},
	onblur : function(node) {
		if (node.value == '' || node.value == this.initValue) {
			node.value = this.initValue;
			JLJS.classAttr.remove(node, this.CLASS_TXBLA);
		}else{
			JLJS.classAttr.add(node, this.CLASS_TXBLA);
		}
		return false;
	},
	onfocus : function(node) {
		if (node.value == this.initValue){
			node.value = '';
		}
		JLJS.classAttr.add(node, this.CLASS_TXBLA);

		return false;
	}
}
var JLJS_InsiteSearch = new JLJS_InsiteSearchKeywordEvent();
JLJS.addOnload(function() {
	var insiteSearchForm = document.forms[JLJS_InsiteSearch.INSITE_SEARCH_FORM];
	if(insiteSearchForm && insiteSearchForm.keyword && insiteSearchForm.keyword.type == "text") {
		JLJS_InsiteSearch.onload(insiteSearchForm);
	}
});
