1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
\r
3 Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved.
\r
4 For licensing, see LICENSE.html or http://ckeditor.com/license
\r
6 <html xmlns="http://www.w3.org/1999/xhtml">
\r
8 <title>Using TableResize Plugin — CKEditor Sample</title>
\r
9 <meta content="text/html; charset=utf-8" http-equiv="content-type" />
\r
10 <script type="text/javascript" src="../ckeditor.js"></script>
\r
11 <script src="sample.js" type="text/javascript"></script>
\r
12 <link href="sample.css" rel="stylesheet" type="text/css" />
\r
15 <h1 class="samples">
\r
16 CKEditor Sample — Using the TableResize Plugin
\r
18 <div class="description">
\r
20 This sample shows how to configure CKEditor instances to use the
\r
21 <strong>TableResize</strong> (<code>tableresize</code>) plugin that allows
\r
22 the user to edit table columns by using the mouse.
\r
25 The TableResize plugin makes it possible to modify table column width. Hover
\r
26 your mouse over the column border to see the cursor change to indicate that
\r
27 the column can be resized. Click and drag your mouse to set the desired width.
\r
30 By default the plugin is turned off. To add a CKEditor instance using the
\r
31 TableResize plugin, insert the following JavaScript call into your code:
\r
33 <pre class="samples">CKEDITOR.replace( '<em>textarea_id</em>',
\r
35 <strong>extraPlugins : 'tableresize'</strong>
\r
38 Note that <code><em>textarea_id</em></code> in the code above is the <code>id</code> attribute of
\r
39 the <code><textarea></code> element to be replaced with CKEditor.
\r
42 <!-- This <div> holds alert messages to be display in the sample page. -->
\r
46 <strong>CKEditor requires JavaScript to run</strong>. In a browser with no JavaScript
\r
47 support, like yours, you should still see the contents (HTML data) and you should
\r
48 be able to edit it normally, without a rich editor interface.
\r
52 <form action="sample_posteddata.php" method="post">
\r
54 <label for="editor1">
\r
55 CKEditor using the <code>tableresize</code> plugin:</label>
\r
56 <textarea cols="80" id="editor1" name="editor1" rows="10">
\r
57 <table style="width: 500px;">
\r
59 A sample table</caption>
\r
69 You can resize a table column.</td>
\r
71 Hover your mouse over its border.</td>
\r
75 Watch the cursor change.</td>
\r
77 Now click and drag to resize.</td>
\r
84 <script type="text/javascript">
\r
87 // This call can be placed at any point after the
\r
88 // <textarea>, or inside a <head><script> in a
\r
89 // window.onload event handler.
\r
91 // Replace the <textarea id="editor"> with an CKEditor
\r
92 // instance, using default configurations.
\r
93 CKEDITOR.replace( 'editor1', {
\r
94 extraPlugins : 'tableresize'
\r
101 <input type="submit" value="Submit" />
\r
107 CKEditor - The text editor for the Internet - <a class="samples" href="http://ckeditor.com/">http://ckeditor.com</a>
\r
110 Copyright © 2003-2012, <a class="samples" href="http://cksource.com/">CKSource</a> - Frederico
\r
111 Knabben. All rights reserved.
\r