includes/clientside/tinymce/plugins/autosave/editor_plugin.js
author Dan
Thu, 27 Dec 2007 11:35:00 -0500
changeset 339 5d62ef764b0d
parent 1 fe660c52c48f
child 335 67bd3121a12e
permissions -rw-r--r--
Fixed search indexer causing duplicate keys when two "words" of 64+ characters encountered and first 64 characters are the same (thanks Vadi); attempt to fix onunload confirmation during page editing

tinyMCE.importPluginLanguagePack('autosave');var TinyMCE_AutoSavePlugin={getInfo:function(){return{longname:'Auto save',author:'Moxiecode Systems AB',authorurl:'http://tinymce.moxiecode.com',infourl:'http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/autosave',version:tinyMCE.majorVersion+"."+tinyMCE.minorVersion}},_beforeUnloadHandler:function(){var n,inst,anyDirty=false,msg=tinyMCE.getLang("lang_autosave_unload_msg");if(tinyMCE.getParam("fullscreen_is_enabled"))return;for(n in tinyMCE.instances){inst=tinyMCE.instances[n];if(!tinyMCE.isInstance(inst))continue;if(inst.isDirty())return msg}return}};window.onbeforeunload=TinyMCE_AutoSavePlugin._beforeUnloadHandler;tinyMCE.addPlugin("autosave",TinyMCE_AutoSavePlugin);