var netLevelsCache = {};
//var guardianNote = null;
-
/* fetch the necessary data to start off */
function uEditInit() {
setTimeout( function() {
uEditBuild(); uEditShowPage('uedit_userid'); }, 20 );
+
+ /*
+ window.onunload = function() {
+ if( ! confirm($('ue_unsaved_changes').innerHTML) )
+ location.href = location.href;
+ }
+ */
+
+
+}
+
+function uEditSetUnload() {
+ window.onbeforeunload = function(evt) {
+ //evt.returnValue = ('ue_unsaved_changes').innerHTML;
+ return $('ue_unsaved_changes').innerHTML;
+ };
+}
+
+function uEditClearUnload() {
+ window.onbeforeunload = null;
}
/* ------------------------------------------------------------------------------ */
uEditIterateFields(function(f) { uEditCheckValid(f); });
uEditCheckErrors();
+
+ uEditSetUnload();
}
req.send(true);
var newuser = req.result();
+ uEditClearUnload();
+
var evt;
if( (evt = checkILSEvent(newuser)) || ! newuser ) {
if(evt) {