1
tzvook
How to make the Content module to work with Inbetween
  • 2006/3/13 14:17

  • tzvook

  • Just can't stay away

  • Posts: 875

  • Since: 2003/2/1 2


Hello All
Since I wanted my users to work with Inbetween in all site modules and the "content" module was working only with FCKeditor, I replaced it with the Inbetween.

I use the improved version from: http://products.thirdeyesoftware.com./ .... so line numbers might be a bit different for the UNhacked version, but still supposed to work fine.

For those who R interested, go to modules/content/admin/index.php look (around line 251) for :

if ($xoopsModuleConfig['cont_wysiwyg'] == '1') {
        
$fckeditor_root XOOPS_ROOT_PATH.'/modules/content/admin/fckeditor/';
        include 
XOOPS_ROOT_PATH.'/modules/content/admin/fckeditor/fckeditor.php';
        
ob_start();
        
$oFCKeditor = new FCKeditor('message') ;
        
$oFCKeditor->BasePath    XOOPS_URL."/modules/content/admin/fckeditor/" ;
        
$oFCKeditor->Value        $message ;
        
$oFCKeditor->Height        500 ;
        
$oFCKeditor->Create() ;
        
$form->addElement(new XoopsFormLabel(_C_CONTENTob_get_contents()));
        
ob_end_clean();
    } else {
        
$t_area = new XoopsFormDhtmlTextArea(_C_CONTENT'message'''3735);
        
$form->addElement($t_area);
    }


Replace it with:

if ($xoopsModuleConfig['cont_wysiwyg'] == '1') {
// TZ for Inbetween WYSIWYG //
include_once(XOOPS_ROOT_PATH "/class/xoopseditor/inbetween/forminbetweentextarea.php");

$form->addElement(new XoopsFormInbetweenTextArea(array('caption'=>_C_CONTENT'name'=>'message''value'=>$block['message'], 'width'=>'100%''height'=>'300px'),true));

    } else {
        
$t_area = new XoopsFormDhtmlTextArea(_C_CONTENT'message'''3735);
        
$form->addElement($t_area);
    }


Then (for the "edit page" part) go to around line 412 and look for :

if ($xoopsModuleConfig['cont_wysiwyg'] == '1') {
        
$fckeditor_root XOOPS_ROOT_PATH.'/modules/content/admin/fckeditor/';
        include 
XOOPS_ROOT_PATH.'/modules/content/admin/fckeditor/fckeditor.php';
        
ob_start();
        
$oFCKeditor = new FCKeditor('message') ;
        
$oFCKeditor->BasePath    XOOPS_URL."/modules/content/admin/fckeditor/" ;
        
$oFCKeditor->Value        $message ;
        
$oFCKeditor->Height        500 ;
        
$oFCKeditor->Create() ;
        
$form->addElement(new XoopsFormLabel(_C_CONTENTob_get_contents()));
        
ob_end_clean();
    } else {
        
$t_area = new XoopsFormDhtmlTextArea(_C_CONTENT'message'$message3735);
        
$form->addElement($t_area);
    }


Replace it with :

if ($xoopsModuleConfig['cont_wysiwyg'] == '1') {
// TZ for Inbetween WYSIWYG //
include_once(XOOPS_ROOT_PATH "/class/xoopseditor/inbetween/forminbetweentextarea.php");

$form->addElement(new XoopsFormInbetweenTextArea(array('caption'=>_C_CONTENT'name'=>'message''value'=>$message'width'=>'100%''height'=>'300px'),true));

    } else {
        
$t_area = new XoopsFormDhtmlTextArea(_C_CONTENT'message'''3735);
        
$form->addElement($t_area);
    }

2
Lance_
Re: How to make the Content module to work with Inbetween
  • 2006/3/13 14:38

  • Lance_

  • Home away from home

  • Posts: 983

  • Since: 2004/1/12


Thanks, I'll give this a whirl tonight.
GDL-Web.com :: Website development.
Xoopslance.com::Freelancing and Projects
thelionsden-arena.net:: Clan/League/Ladder Hosting

Login

Who's Online

414 user(s) are online (305 user(s) are browsing Support Forums)


Members: 0


Guests: 414


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits