1. 程式人生 > >在html中引入線上編輯器的程式碼

在html中引入線上編輯器的程式碼

 

<form action="disp.php" method="post">

<?php

//引用FCKeditor.php這個檔案,基本的類和資料結構都在這裡

include ("fckeditor/fckeditor.php");

//建立FCKeditor物件的例項。myFCKeditor即提交後,接收資料頁面 _POST['myFCKeditor']使用

$FCKeditor = new FCKeditor("content");

//FCKeditor所在的位置,這裡它的位置就是'FCKeditor' 資料夾

$FCKeditor -> BasePath='./fckeditor/';

//工具按鈕設定

$FCKeditor -> ToolbarSet="Default";

//設定它的寬度

$FCKeditor -> Width='500px';

//設定它的高度

$FCKeditor -> Height='300px';

//生成

$FCKeditor -> Create();

?>

<input type="submit" value="提交">

</form>