Ticket #6521: 6521_3.patch

File 6521_3.patch, 4.7 KB (added by Anna Tomanek, 13 years ago)

Samples corrected.

  • _samples/index.html

     
    8282                <li><a class="samples" href="placeholder.html">Placeholder plugin</a><br />
    8383                        Using the Placeholder plugin to create uneditable sections that can only be created and modified with a proper dialog window.
    8484                </li>
     85                <li><a class="samples" href="tableresize.html">TableResize plugin</a><br />
     86                        Using the TableResize plugin to enable table column resizing.
     87                </li>
    8588        </ul>
    8689        <div id="footer">
    8790                <hr />
  • _samples/tableresize.html

     
     1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
     2<!--
     3Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
     4For licensing, see LICENSE.html or http://ckeditor.com/license
     5-->
     6<html xmlns="http://www.w3.org/1999/xhtml">
     7<head>
     8        <title>Using TableResize Plugin &mdash; CKEditor Sample</title>
     9        <meta content="text/html; charset=utf-8" http-equiv="content-type" />
     10        <!-- CKReleaser %REMOVE_LINE%
     11        <script type="text/javascript" src="../ckeditor.js"></script>
     12        CKReleaser %REMOVE_START% -->
     13        <script type="text/javascript" src="../ckeditor_source.js"></script>
     14        <!-- CKReleaser %REMOVE_END% -->
     15        <script src="sample.js" type="text/javascript"></script>
     16        <link href="sample.css" rel="stylesheet" type="text/css" />
     17</head>
     18<body>
     19        <h1 class="samples">
     20                CKEditor Sample &mdash; Using the TableResize Plugin
     21        </h1>
     22        <div class="description">
     23        <p>
     24                This sample shows how to configure CKEditor instances to use the
     25                <strong>TableResize</strong> (<code>tableresize</code>) plugin that allows
     26                the user to edit table columns by using the mouse.
     27        </p>
     28        <p>
     29                The TableResize plugin makes it possible to modify table column width. Hover
     30                your mouse over the column border to see the cursor change to indicate that
     31                the column can be resized. Click and drag your mouse to set the desired width.
     32        </p>
     33        <p>
     34                By default the plugin is turned off. To add a CKEditor instance using the
     35                TableResize plugin, insert the following JavaScript call into your code:
     36        </p>
     37        <pre class="samples">CKEDITOR.replace( '<em>textarea_id</em>',
     38        {
     39                <strong>extraPlugins : 'tableresize'</strong>
     40        });</pre>
     41        <p>
     42                Note that <code><em>textarea_id</em></code> in the code above is the <code>id</code> attribute of
     43                the <code>&lt;textarea&gt;</code> element to be replaced with CKEditor.
     44        </p>
     45        </div> 
     46        <!-- This <div> holds alert messages to be display in the sample page. -->
     47        <div id="alerts">
     48                <noscript>
     49                        <p>
     50                                <strong>CKEditor requires JavaScript to run</strong>. In a browser with no JavaScript
     51                                support, like yours, you should still see the contents (HTML data) and you should
     52                                be able to edit it normally, without a rich editor interface.
     53                        </p>
     54                </noscript>
     55        </div>
     56        <form action="sample_posteddata.php" method="post">
     57                <p>
     58                        <label for="editor1">
     59                                Editor 1:</label><br />
     60                        <textarea cols="80" id="editor1" name="editor1" rows="10">
     61&lt;table style="width: 500px;"&gt;
     62        &lt;caption&gt;
     63                A sample table&lt;/caption&gt;
     64        &lt;tbody&gt;
     65                &lt;tr&gt;
     66                        &lt;td&gt;
     67                                Column 1&lt;/td&gt;
     68                        &lt;td&gt;
     69                                Column 2&lt;/td&gt;
     70                &lt;/tr&gt;
     71                &lt;tr&gt;
     72                        &lt;td&gt;
     73                                You can resize a table column.&lt;/td&gt;
     74                        &lt;td&gt;
     75                                Hover your mouse over its border.&lt;/td&gt;
     76                &lt;/tr&gt;
     77                &lt;tr&gt;
     78                        &lt;td&gt;
     79                                Watch the cursor change.&lt;/td&gt;
     80                        &lt;td&gt;
     81                                Now click and drag to resize.&lt;/td&gt;
     82                &lt;/tr&gt;
     83        &lt;/tbody&gt;
     84&lt;/table&gt;
     85
     86
     87                        </textarea>
     88                        <script type="text/javascript">
     89                        //<![CDATA[
     90
     91                                // This call can be placed at any point after the
     92                                // <textarea>, or inside a <head><script> in a
     93                                // window.onload event handler.
     94
     95                                // Replace the <textarea id="editor"> with an CKEditor
     96                                // instance, using default configurations.
     97                                CKEDITOR.replace( 'editor1', {
     98                                        extraPlugins : 'tableresize'
     99                                });
     100
     101                        //]]>
     102                        </script>
     103                </p>
     104                <p>
     105                        <input type="submit" value="Submit" />
     106                </p>
     107        </form>
     108        <div id="footer">
     109                <hr />
     110                <p>
     111                        CKEditor - The text editor for the Internet - <a class="samples" href="http://ckeditor.com/">http://ckeditor.com</a>
     112                </p>
     113                <p id="copy">
     114                        Copyright &copy; 2003-2011, <a class="samples" href="http://cksource.com/">CKSource</a> - Frederico
     115                        Knabben. All rights reserved.
     116                </p>
     117        </div>
     118</body>
     119</html>
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy