index.html 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <!--
  3. Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved.
  4. For licensing, see LICENSE.html or http://ckeditor.com/license
  5. -->
  6. <html xmlns="http://www.w3.org/1999/xhtml">
  7. <head>
  8. <title>ASP integration Samples List &mdash; CKEditor</title>
  9. <link type="text/css" rel="stylesheet" href="../sample.css" />
  10. </head>
  11. <body>
  12. <h1 class="samples">
  13. CKEditor Samples List for ASP &mdash; CKEditor Sample
  14. </h1>
  15. <h2 class="samples">
  16. Overview
  17. </h2>
  18. <p>The ckeditor.asp file provides a wrapper to ease the work of creating CKEditor instances from classic Asp.</p>
  19. <p>To use it, you must first include it into your page:
  20. <code>
  21. &lt;!-- #INCLUDE file="../../ckeditor.asp" --&gt;
  22. </code>
  23. Of course, you should adjust the path to make it point to the correct location, and maybe use a full path (with virtual="" instead of file="")
  24. </p>
  25. <p>After that script is included, you can use it in different ways, based on the following pattern:</p>
  26. <ol>
  27. <li>
  28. Create an instance of the CKEditor class:
  29. <pre class="samples">dim editor
  30. set editor = New CKEditor</pre>
  31. </li>
  32. <li>
  33. Set the path to the folder where CKEditor has been installed, by default it will use /ckeditor/
  34. <pre class="samples">editor.basePath = "../../"</pre>
  35. </li>
  36. <li>
  37. Now use one of the three main methods to create the CKEditor instances:
  38. <ul class="samples">
  39. <li>
  40. Replace textarea with id (or name) "editor1".
  41. <pre class="samples">editor.replaceInstance "editor1"</pre>
  42. </li>
  43. <li>
  44. Replace all textareas with CKEditor.
  45. <pre class="samples">editor.replaceAll empty</pre>
  46. </li>
  47. <li>
  48. Create a textarea element and attach CKEditor to it.
  49. <pre class="samples">editor.editor "editor1", initialValue</pre>
  50. </li>
  51. </ul>
  52. </li>
  53. </ol>
  54. <p>Before step 3 you can use a number of methods and properties to adjust the behavior of this class and the CKEditor instances
  55. that will be created:</p>
  56. <ul class="samples">
  57. <li>returnOutput : if set to true, the functions won't dump the code with response.write, but instead they will return it so
  58. you can do anything you want</li>
  59. <li>basePath: location of the CKEditor scripts</li>
  60. <li>initialized: if you set it to true, it means that you have already included the CKEditor.js file into the page and it
  61. doesn't have to be generated again.</li>
  62. <li>textareaAttributes: You can set here a Dictionary object with the attributes that you want to output in the call to the "editor" method.</li>
  63. <li>config: Allows to set config values for all the instances from now on.</li>
  64. <li>instanceConfig: Allows to set config values just for the next instance.</li>
  65. <li>addEventHandler: Adds an event handler for all the instances from now on.</li>
  66. <li>addInstanceEventHandler: Adds an event handler just for the next instance.</li>
  67. <li>addGlobalEventHandler: Adds an event handler for the global CKEDITOR object.</li>
  68. <li>clearEventHandlers: Removes one or all the event handlers from all the instances from now on.</li>
  69. <li>clearInstanceEventHandlers: Removes one or all the event handlers from the next instance.</li>
  70. <li>clearGlobalEventHandlers: Removes one or all the event handlers from the global CKEDITOR object.</li>
  71. </ul>
  72. <h2 class="samples">
  73. Basic Samples
  74. </h2>
  75. <ul class="samples">
  76. <li><a class="samples" href="replace.asp">Replace existing textareas by code</a></li>
  77. <li><a class="samples" href="replaceall.asp">Replace all textareas by code</a></li>
  78. <li><a class="samples" href="standalone.asp">Create instances in asp</a></li>
  79. </ul>
  80. <h2 class="samples">
  81. Advanced Samples
  82. </h2>
  83. <ul class="samples">
  84. <li><a class="samples" href="advanced.asp">Advanced example</a></li>
  85. <li><a class="samples" href="events.asp">Listening to events</a></li>
  86. </ul>
  87. <div id="footer">
  88. <hr />
  89. <p>
  90. CKEditor - The text editor for the Internet - <a class="samples" href="http://ckeditor.com/">http://ckeditor.com</a>
  91. </p>
  92. <p id="copy">
  93. Copyright &copy; 2003-2011, <a class="samples" href="http://cksource.com/">CKSource</a> - Frederico Knabben. All rights reserved.
  94. </p>
  95. </div>
  96. </body>
  97. </html>