how can i embed two fckeditors on the same page?
My project use PHP, when i initialize two fckeditors on the same page, i got javascript error/warning
First include:
the second include:
My project use PHP, when i initialize two fckeditors on the same page, i got javascript error/warning
First include:
include("editor/fckeditor.php") ; $sBasePath = $_SERVER['PHP_SELF']; $sBasePath = substr( $sBasePath, 0, strpos( $sBasePath, "/" ) )."editor/"; $oFCKeditor = new FCKeditor('content') ; $oFCKeditor->Height = '500' ; $oFCKeditor->BasePath = $sBasePath; $oFCKeditor->ToolbarSet = "events"; $oFCKeditor->Value = stripslashes($content); $oFCKeditor->Create();
the second include:
$oFCKeditor2 = new FCKeditor('content_eng') ; $oFCKeditor2->Height = '500' ; $oFCKeditor2->BasePath = $sBasePath; $oFCKeditor2->ToolbarSet = "events"; $oFCKeditor2->Value = ""; $oFCKeditor2->Config["ContentLangDirection"] = 'ltr'; $oFCKeditor2->Create();
Re: Two fckeditors on the same page
Re: Two fckeditors on the same page
That would just be my guess, though... I've only used this particular editor in ColdFusion where the editors are designed by a variable called "instanceName"
in PHP, I'm assuming that you're naming it with:
$oFCKeditor = new FCKeditor('editor_name_here');
in which every new instance would just have a different name between the quotes
Re: Two fckeditors on the same page
does anyone use two fckeditors on the same page here or not?
Re: Two fckeditors on the same page
I did mine in a function and then called that function for each textarea.
and then call it in the page like so
<?php texteditor('editor1'); ?>
<?php texteditor('editor2'); ?>
Re: Two fckeditors on the same page
I will try
because what's going now it's smth interesting:
If I ignore javascript warning/error, the fckeditor doesn't pass its value by POST ;(
Re: Two fckeditors on the same page
Re: Two fckeditors on the same page
Don't forget i use php version
Re: Two fckeditors on the same page
the trouvle to use 2 fckeditors on the same page was because TextFlow plugin (adds RTL support)