이것은 내가 할 노력하고있어입니다 입력란을 클릭하고 '제출'을 클릭하면 이 contact.htm으로 이동합니다. jQuery를 탐색 (.HTM)는
내가 비슷한 here (학점)jQuery를 발견
jQuery(function() {
$(document).ready(function() {
function goTo() {
window.location = where.value + '.htm';
return false;
}
});
HTML :
<form action="" method="post" onsubmit="return goTo()">
<input type="text" name="where" value="looking for"
onfocus="if(this.value == this.defaultValue) this.value = '';
"onblur="if(this.value == '') this.value = this.defaultValue;">
<input type="submit" value="Go">
</form>
당신에게 나의 질문은; 입력을 제출 한 후에이 코드는 전혀 탐색하지 않습니다.
올바른 방법인가요? : window.location = where.value + '.htm';
Ofcourse, 그건 의미가 있습니다. jQuery는 htm 페이지에 대해 어떻게 인식합니까? – Opoe