echo " <a href=\"" . $template . ".html\">Back to page.</a><br>\n"; page_close(); exit; } } if ($text) { echo "<form name='EditorForm' id='EditorForm' method='post'>\n"; if ($_ENV["SubFolder"]) { $sf = "/" . $_ENV["SubFolder"] . "/"; } $finder = ""; switch ($_ENV["editor"]) { case "fckeditor": $editor = new FCKeditor('content'); $editor->BasePath = 'fckeditor/'; $editor->Config['EditorAreaCSS'] = 'css/style.css'; $editor->Width = '880'; $editor->Height = '500'; $editor->Value = stripslashes($text); $editor->editor('content', stripslashes($text)); break; case "ckfinder": $finder = "CKFinder.SetupCKEditor(editor);"; case "ckeditor": echo "<textarea name='{$fieldname}' rows=200 cols=40></textarea>\n\t\t<script>var editor=CKEDITOR.replace(\"{$this->name}\", {\n toolbarStartupExpanded : true\n });{$finder}</script>"; break; } echo "</form>\n"; } // if text page_close();