구매고객
판매자
솔루션별 질문
var href = $(this).attr("href")+"&js=on"; $(this).attr("href", href); return true;
자바스크립트 click(function() 이벤트에서 return true; 후 창 새로고침을 하고싶은데
아무리해봐도 되질 않더라구요
방법이 없을까요?
function temp(){
//기존 함수 var href = $(this).attr("href")+"&js=on"; $(this).attr("href", href); return true; } function reload(){
//기존함수의 결과를 받는 추가함수 if(temp()){ location.reload(); } }
이런식으로 호출하는 구간을 상위로 하나 더 만들어주고 결과값으로 처리하면 되지 않을까요
location.reload();
이렇게 해 보셨나요??
답변을 작성하려면 로그인이 필요합니다.
광고가 아닌 글을 신고하면 회원님의 신고 권한이 제한될 수 있습니다. 신중하게 신고해 주세요.
var href = $(this).attr("href")+"&js=on";
$(this).attr("href", href);
return true;
location.reload();
[/code]
리턴이후에 location.reload(); 넣어도 무시되더라구요