total.html 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <!doctype html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8" />
  5. <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
  6. <title>KindEditor Test</title>
  7. </head>
  8. <body>
  9. <h1 id="type">KindEditor Test</h1>
  10. <form method="post" action="../php/demo.php">
  11. <textarea name="editor1" cols="100" rows="20" style="width:800px;height:200px;"></textarea>
  12. <br />
  13. <textarea name="editor2" cols="100" rows="20" style="width:700px;height:100px;"></textarea>
  14. <br />
  15. <textarea name="editor3" cols="100" rows="20" style="width:700px;height:100px;"></textarea>
  16. <br />
  17. <textarea name="editor4" cols="100" rows="20" style="width:700px;height:100px;"></textarea>
  18. <br />
  19. <textarea name="editor5" cols="100" rows="20" style="width:700px;height:100px;"></textarea>
  20. <br />
  21. <input type="button" id="create1" value="Create #1" />
  22. <input type="button" id="create2" value="Create #2" />
  23. <input type="button" id="remove1" value="Remove #1" />
  24. <input type="button" id="remove2" value="Remove #2" />
  25. <input type="button" id="removeAll" value="Remove all" />
  26. <input type="reset" name="button" value="Reset" />
  27. <!-- <iframe src="http://www.kindsoft.net/"></iframe> -->
  28. <script src="../kindeditor-all.js"></script>
  29. <script>
  30. //document.domain = 'domain.com';
  31. KindEditor.ready(function(K) {
  32. window.editor = K.create('textarea', {
  33. allowFileManager : true,
  34. langType : 'zh-CN',
  35. autoHeightMode : true
  36. });
  37. K('#removeAll').click(function(e) {
  38. K.remove('textarea');
  39. });
  40. K('#create1').click(function(e) {
  41. K.instances[0].create();
  42. });
  43. K('#remove1').click(function(e) {
  44. K.instances[0].remove();
  45. });
  46. K('#create2').click(function(e) {
  47. K.instances[1].create();
  48. });
  49. K('#remove2').click(function(e) {
  50. K.instances[1].remove();
  51. });
  52. });
  53. </script>
  54. </form>
  55. </body>
  56. </html>