CLICK HERE TO BUY IT TODAY! OR GET IT FREE VIA TRIALPAY  

PHP Demo Application - Source Code

/Framework/Model/Vendor/CkEditor/_source/plugins/save/plugin.js



/*
Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.html or http://ckeditor.com/license
*/
/**
 * @fileSave plugin.
 */
(function()
{
	    var saveCmd =
	    {
		        modes : { wysiwyg:1source:1
			},
		        exec : function( editor )
		        {
			            var $form editor.element.$.form;
			            if ( $form )
			            {
				                try
				                {
					                    $form.submit();
					                }
				                catch( )
				                {
					                    // If there's a button named "submit" then the form.submit
					                    // function is masked and can't be called in IE/FF, so we
					                    // call the click() method of that button.
					                    if ( $form.submit.click )
					                        $form.submit.click();
					                }
				            }
			        }
		    };
	    var pluginName 'save';
	    // Register a plugin named "save".
	    CKEDITOR.plugins.addpluginName,
	    {
		        init : function( editor )
		        {
			            var command editor.addCommandpluginNamesaveCmd );
			            command.modes = { wysiwyg : !!( editor.element.$.form )
				};
			            editor.ui.addButton'Save',
			                {
				                    label editor.lang.save,
				                    command pluginName
				                });
			        }
		    });
	})();





PHP Demo Source Code Index