다음과 같이 페이지를 벗어나기 전에, ‘수정사항이 있으니 다시 한번 확인해보세요’라는 메시지를 구현하는 방법에 대한 정리입니다. Javascript의 window.onBeforeUnload Event를 이용한 기능입니다. 실행시점 window.onBeforeUnload Event는 Window개체가 Unload되기 전에 실행됩니다. 정확하게 다음과 같은 시점이 있을 수 있습니다. 다만 IE 7, 8에서는 버그로 인해 다르게 동작하는 경우도 있으므로 참고가 필요합니다. 창이나 탭을 닫을 때 새로고침, 앞, 뒤로 이동버튼 클릭 시 location.href 변경 Form Submit 발생 시 A Tag 클릭 시 HREF에 URL을 지정한 경우: 발생 HREF에 #을 지정한 경우: 발생 안함 HREF에 java..
가 한 개가 아니라는걸 간과해서 protocol 이 HTTP/1.1 인 에만 설정을 하는 것입니다. 중에 protocol="HTTP/1.1" SSLEnabled="true" scheme="https" secure="true" clientAuth="false" sslProtocol="TLS" 등의 값이 포함된 다른 에도 URIEncoding 을 적어줘야 하고, mod_jk 을 통해서 처리하는 거라면 AJP/1.3 쪽 에서도 처리를 해야 합니다. https 443 Connector에 URIEncoding="UTF-8" 추가 후 해결,
Just discovered how super simple it was to add some gz compression when for example providing JSON data from PHP. All you need is regular output buffering with the ob_gzhandler as output callback. // Fetch some data $data = get_data(); // Turn on output buffering with the gzhandler ob_start('ob_gzhandler'); // Output as normal echo json_encode($data); The cool thing is that it actually looks at ..
var url_regex = /(http(s)?:\/\/([\w-]+\.)+[\w-]+(\/[\w-.\/?%&=]*)?)/gi; var email_regex = /([a-zA-Z0-9._-]+@[a-zA-Z0-9._-]+\.[a-zA-Z0-9._-]+)/gi; var string = "도메인은 http://www.huzy.net/ 이고 이메일은 root@yjhoon.com 입니다."; var url_result = string.match(url_regex); => ["http://www.huzy.net/"] var email_result = string.match(email_regex); => [root@yjhoon.com"] result 값은 둘다 배열로 리턴되서 나옴 .
