e = document.getElementById(inputID).value; if(!(/^\d+$/).test(inputValue)){ document.getElementById(inputID).value = '801'; return; } if(inputValue <= 0) { inputValue = 1; } if(inputValue > 80) { inputValue = 80; } location.href = '/ccscnews/list_page_{$wtl_pager}.html'.replace('{$wtl_pager}', inputValue); }