// Perform a roundtrip, without updating any database function roundtrip() { if(document.theForm) { if(document.theForm._action) document.theForm._action.value = 'roundtrip'; cms_formunchange(); // Prevent a warning in Safari document.theForm.submit(); } } function mark_submitted() { if(document.theForm && document.theForm._submitted) document.theForm._submitted.value = 1; top.cms_submitted=1; cms_formunchange(); // Prevent a warning in Safari } // Submit values with updates! function submit() { mark_submitted(); document.theForm.submit(); } function check_form(form) { var returnval = check_form_fields(form); if(returnval) { // Ready for sending. Let's check if there are any upload forms, filled in. var inputs = document.getElementsByTagName('input'); for(var i=0; i0) return; if(document.theForm && document.theForm._action && (document.theForm._action.value == 'roundtrip')) return; if (top.cms_formchanged) { var message = "U hebt wijzigingen gemaakt, die nog niet zijn opgeslagen"; if(typeof(window.event) != 'undefined') window.event.returnValue = message; else return(message); } return(''); } // check formchanges function cms_chkformchange_unload(sel) { if(top.cms_chkformchange_before_called) return 1; if(top.cms_submitted>0) return 1; if(document.theForm && document.theForm._action && (document.theForm._action.value == 'roundtrip')) return 1; if (top.cms_formchanged) { alert("U hebt het formulier verlaten, zonder de wijzigingen te bewaren.\n"+ "Met de back toets van uw browser kunt U weer terug komen "+ "en de wijzigingen opnieuw maken."); return 0; } } // ************ General form functions *************// function DeleteItem(itemtype, id) { RetVal = confirm("'"+itemtype+"' Verwijderen, Weet u het zeker?"); if (RetVal == false) return; document.theForm._action.value = 'delete'+':'+id; document.theForm.submit(); } function GenPassword(theField) { // Generate new password... Use = "0123456789abcdefghijklmnopqrstuvwxyz@#$%*"; UseLen = Use.length; PassLen = 8; // Minimal required length... Pass = ""; for (karak=0; karak