var is_chrome = navigator.userAgent.toLowerCase().indexOf('chrome') > -1;
if($("textarea#editor")[0].value != answer) {
if(is_chrome) {
- return "You sure you want to leave? Your work will be lost.";
+ return "Are you sure you want to leave? Your work will be lost.";
} else {
yourWorkWillBeLost(e);
}
- return false;
}
}
window.addEventListener('beforeunload', beforeUnload, true);
-
var answer = "";
- var is_chrome = navigator.userAgent.toLowerCase().indexOf('chrome') > -1;
</script>
{% endblock %}
function beforeUnload(e) {
if($("input#id_title")[0].value != "" || $("textarea#editor")[0].value != "" || $("input#id_tags")[0].value != "") {
if(is_chrome) {
- return "You sure you want to leave? Your work will be lost.";
+ return "Are you sure you want to leave? Your work will be lost.";
} else {
yourWorkWillBeLost(e);
}
}
- return false;
}
window.addEventListener('beforeunload', beforeUnload, true);
\r
if($("textarea#editor")[0].value != "") {\r
if(is_chrome) {\r
- return "You sure you want to leave? Your work will be lost.";\r
+ return "Are you sure you want to leave? Your work will be lost.";\r
} else {\r
yourWorkWillBeLost(e);\r
}\r
- return false;\r
}\r
\r
var commentBoxes = $("textarea.commentBox");\r
} else {\r
yourWorkWillBeLost(e);\r
}\r
- return false;\r
}\r
}\r
}\r
window.addEventListener('beforeunload', beforeUnload, true);\r
-\r
- var is_chrome = navigator.userAgent.toLowerCase().indexOf('chrome') > -1;\r
</script>\r
<noscript>\r
<style>\r
} else {
yourWorkWillBeLost(e);
}
- return false;
}
}
window.addEventListener('beforeunload', beforeUnload, true);
var title = "";
var body = "";
var tag = "";
- var is_chrome = navigator.userAgent.toLowerCase().indexOf('chrome') > -1;
</script>
{% endblock %}