반응형
jQuery - Back button Detect, reload http://www.vvaves.net/jquery-backDetect/
브라우저에서 뒤로가기 버튼 선택시 페이지를 리로드해주는 쿼리.
단, 라이브러리를 업로드해야 한다.
https://github.com/ianrogren/jquery-backDetect
backDetect
Determining when a user clicks their browser's back button has never been easier with this jQuery plugin. With a quick easy install and minimal set up work you'll be firing callback functions on back button declarations in no time.
View the Project on GitHubianrogren/jquery-backDetect
Using jQuery-backDetect
Can append to any element or class:
$(window).load(function(){ $('body').backDetect(function(){ // Callback function alert("Look forward to the future, not the past!"); }); });</script>
Click the back button to test.
반응형
'프로그래밍 > Web' 카테고리의 다른 글
SVG animation example (0) | 2019.06.03 |
---|---|
유트브영상 DIV 밑에 위치하기, wmode=opaque (0) | 2019.06.03 |
jQuery - URL add Hash, get Hash (0) | 2019.05.13 |
Link rel="canonical" - 별도 url, 검색봇에 최적화하기위한. (0) | 2019.05.10 |
Fiddler - 웹 디버깅 프록시 web debugging proxy (0) | 2019.04.17 |