If you have created an admin section in your newly designed Joomla! component, or you have a frontend page where you want your website users to write something cool using an RTE, like this one, its just a few lines of code.
Assuming you are using MVC design pattern in Joomla! Extension development. Suppose,
Component Name = cmp
View Name = vvv
So we must have a class named cmpViewvvv (Learn more on naming conventions for classes in Joomla!)
Code for view.html.php
<?php class cmpViewvvv extends JView { function display($tpl = null){ $editor =& JFactory::getEditor(); $this->assignRef('editor', $editor); } } ?>
Code for default.php
<?php defined( '_JEXEC' ) or die( 'Restricted Access' ); ---- ---- ---- ?> <form action="index.php" method="post"> ---- ---- ---- <?php echo $this->editor; ?> ---- ---- ---- </form>
Easy

