TShopping

標題: FCKeditor 2.6.5版 使用方法 [打印本頁]

作者: woff    時間: 2010-2-17 17:13
標題: FCKeditor 2.6.5版 使用方法
預設FCKeditor目錄為 editor
在該目錄下使用方法如下:
  1. <?php

  2. include("fckeditor.php");
  3. $sBasePath = $_SERVER['PHP_SELF'];
  4. $sBasePath = dirname($sBasePath).'/';
  5. $ed = new FCKeditor('con');
  6. $ed->BasePath= $sBasePath

  7. ?>
  8. <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post" name="form1">
  9. <table cellpadding="0" cellspacing="0" border="1" width="100%">
  10. <tr><td>主題:</td><td><input type="text" name="title" /></td></tr>
  11. <tr><td>內文:</td>
  12. <td><?php $ed->Create(); ?></td>
  13. </tr>
  14. <tr><td colspan="2"><input type="submit" name="send" value="發文"/></td></tr>
  15. </table>
  16. </form>
複製代碼


如果要編輯的檔案要放在跟目錄下的處理方法
修改上述找到
  1. include("fckeditor.php");
  2. $sBasePath = $_SERVER['PHP_SELF'];
  3. $sBasePath = dirname($sBasePath).'/';
  4. $ed = new FCKeditor('con');
  5. $ed->BasePath= $sBasePath
複製代碼


更改為
  1. include("editor/fckeditor.php");
  2. $ed = new FCKeditor('con');
  3. $ed->BasePath= 'editor/';
複製代碼

如果不這樣改  會顯示  此網頁不存在
作者: QOOQOO5320    時間: 2012-7-30 00:46
必須頂.............  




歡迎光臨 TShopping (http://www.tshopping.com.tw/) Powered by Discuz! X3.2