I've got a Joomla 1.5 ingredient that utilizes a call towards the editor class to show the JCE editor for Joomla rather than a textbox. This code is a component of the 4 step form where each step is loading using Ajax. The final step consists of a note area where customers can write free text and i'm calling this while using following code:

$editor =& JFactory::getEditor();
echo $editor->display('description', $description, '100%', '150', '40', '30');

If this step is displayed, it shows merely a simple textbox with no buttons to format the written text etc. I realize this should be an problem using the javascript, however i am getting a difficult time finding the way i can trigger the correct code for that textbox to become formatted correctly.

I've attached a screenshot of methods the area appears like. Description field loaded via Ajax

Here is the HTML produced from Firebug:

<!-- Start Editor --><label aria-visible="false" style="display:none;" for="description">description_textarea</label><textarea wrap="off" class="wfEditor source" style="width:100%;height:150px;" rows="30" cols="40" name="description" id="description"></textarea><input type="hidden" value="1" name="wf3fadc9c48cabc28750287fe69c3d08c4" id="wf_description_token">
<div id="editor-xtd-buttons">
<div class="button2-left"><div class="image"><a rel="{handler: 'iframe', size: {x: 570, y: 400}}" onclick="IeCursorFix(); return false;" href="http://localhost/ugparl/site/index.php?option=com_media&amp;view=images&amp;tmpl=component&amp;e_name=description" title="Image" class="modal-button">Image</a></div></div>
<div class="button2-left"><div class="pagebreak"><a rel="{handler: 'iframe', size: {x: 400, y: 85}}" onclick="IeCursorFix(); return false;" href="http://localhost/ugparl/site/index.php?option=com_content&amp;task=ins_pagebreak&amp;tmpl=component&amp;e_name=description" title="Pagebreak" class="modal-button">Pagebreak</a></div></div>
<div class="button2-left"><div class="readmore"><a rel="" onclick="insertReadmore('description');return false;" href="http://localhost/ugparl/site/#" title="Read more">Read more</a></div></div>
<!-- End Editor -->

Thanks ahead of time for just about any assist you to can offer.

This isn't a lot an answer but a workaround. Because of washing the headers before exhibiting the page, the code produced by JCE sheds. With the addition of the next code towards the page known as by ajax, I can trigger the JCE initializer and display the editor properly.

$document =& JFactory::getDocument();
echo "<script type='text/javascript'>
function loadJCE() {";
echo $document->_script["text/javascript"];
echo "}

I Quickly just known as loadJCE in the load complete function.

Again, this isn't the easiest method to get it done however it have been effective for me personally.