Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script type='text/javascript' src='../_Js/jquery.simplemodal.js'></script>
- <script>
- jQuery(function ($) {
- $('.edit').click(function (e) {
- $('#blog-edit-content').modal();
- return false;
- });
- });
- </script>
- <a class="edit" style="font-size:16px;color:#CCC;" href="">Edit</a>
- <div id="blog-edit-content" style="display:none;">
- <form name="newblog" id="newblog" action="#" method="post">
- <font color="#000000"><strong>Title: </strong></font>
- <input name="blogtitle" id="blogtitle" type="text" id="title" size="80" maxlength="255" value="'.$blogtitle.'" /><br /><br />
- <textarea class="ckeditor" cols="80" id="blog-edit-body" name="blog-edit-body" rows="10"></textarea><br />
- Please separate tages with a <strong>comma</strong>.<br />
- <font color="#000000"><strong>Tags: </strong></font>
- <input name="tags" id="tags" type="text" size="80" maxlength="255" alue="tags" /><br /><br />
- <input type="submit" value="Post Blog" />
- <span id="blogFormProcessGif" style="display:none;">
- <img src="../_Images/loading.gif" width="28px" height="28px" alt="Loading" />
- </span>
- </form>
- </div>
- <!DOCTYPE html>
- <!--
- Copyright (c) 2003-2013, CKSource - Frederico Knabben. All rights reserved.
- For licensing, see LICENSE.md or http://ckeditor.com/license
- -->
- <html>
- <head>
- <meta charset="utf-8">
- <title>API Usage — CKEditor Sample</title>
- <script src="ckeditor/ckeditor.js"></script>
- <link href="sample.css" rel="stylesheet">
- <script>
- // The instanceReady event is fired, when an instance of CKEditor has finished
- // its initialization.
- CKEDITOR.on( 'instanceReady', function( ev ) {
- // Show this sample buttons.
- document.getElementById( 'eButtons' ).style.display = 'block';
- });
- function GetContents() {
- // Get the editor instance that you want to interact with.
- var editor = CKEDITOR.instances.editor1;
- // Get editor contents
- // http://docs.ckeditor.com/#!/api/CKEDITOR.editor-method-getData
- alert( editor.getData());
- }
- function Focus() {
- CKEDITOR.instances.editor1.focus();
- }
- function onFocus() {
- document.getElementById( 'eMessage' ).innerHTML = '<b>' + this.name + ' is focused </b>';
- }
- function onBlur() {
- document.getElementById( 'eMessage' ).innerHTML = this.name + ' lost focus';
- }
- </script>
- </head>
- <body>
- <h1 class="samples">
- <noscript>
- </noscript>
- </h1>
- <form action="../../../samples/sample_posteddata.php" method="post">
- <textarea cols="100" id="editor1" name="editor1" rows="10"><p>This is some <strong>sample text</strong>. You are using <a href="http://ckeditor.com/">CKEditor</a>.</p></textarea>
- <script>
- // Replace the <textarea id="editor1"> with an CKEditor instance.
- CKEDITOR.replace( 'editor1', {
- on: {
- focus: onFocus,
- blur: onBlur,
- // Check for availability of corresponding plugins.
- pluginsLoaded: function( evt ) {
- var doc = CKEDITOR.document, ed = evt.editor;
- if ( !ed.getCommand( 'bold' ) )
- doc.getById( 'exec-bold' ).hide();
- if ( !ed.getCommand( 'link' ) )
- doc.getById( 'exec-link' ).hide();
- }
- }
- });
- </script>
- </form><br>
- <input type="button" onClick="javascript:GetContents()" value="Save"/>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement