1
assniok
could you help me with koivi editor ?
  • 2004/11/24 9:28

  • assniok

  • Just popping in

  • Posts: 15

  • Since: 2002/9/13


hello,

i use koivi with newbb2 module but i can't use with another module :(

i try tu use with module news, and a have just modify storyform.inc.php and i have this :

include XOOPS_ROOT_PATH."/class/xoopsformloader.php";
include_once 
XOOPS_ROOT_PATH."/class/wysiwyg/formwysiwygtextarea.php";
$sform = new XoopsThemeForm(_NW_SUBMITNEWS"storyform"xoops_getenv('PHP_SELF'));
$sform->addElement(new XoopsFormText(_NW_TITLE'subject'80255$subject), true);
ob_start();
$xt->makeTopicSelBox(0);
$sform->addElement(new XoopsFormLabel(_NW_TOPICob_get_contents()));
ob_end_clean();
$sform->addElement($topic_select);
$sform->addElement(new XoopsFormWysiwygTextArea(_NW_THESCOOP'message'$message'100%''400px',''), true);
$option_tray = new XoopsFormElementTray(_OPTIONS,'<br />');
if (
$xoopsUser) {
    if (
$xoopsConfig['anonpost'] == 1) {
        
$noname_checkbox = new XoopsFormCheckBox('''noname'$noname);
        
$noname_checkbox->addOption(1_POSTANON);
        
$option_tray->addElement($noname_checkbox);
    }
    
$notify_checkbox = new XoopsFormCheckBox('''notifypub'$notifypub);
    
$notify_checkbox->addOption(1_NW_NOTIFYPUBLISH);
    
$option_tray->addElement($notify_checkbox);
    if (
$xoopsUser->isAdmin($xoopsModule->getVar('mid'))) {
        
$nohtml_checkbox = new XoopsFormCheckBox('''nohtml'$nohtml);
        
$nohtml_checkbox->addOption(1_DISABLEHTML);
        
$option_tray->addElement($nohtml_checkbox);
    }
}
$smiley_checkbox = new XoopsFormCheckBox('''nosmiley'$nosmiley);
$smiley_checkbox->addOption(1_DISABLESMILEY);
$option_tray->addElement($smiley_checkbox);
$sform->addElement($option_tray);
$button_tray = new XoopsFormElementTray('' ,'');
$button_tray->addElement(new XoopsFormButton('''preview'_PREVIEW'submit'));
$button_tray->addElement(new XoopsFormButton('''post'_NW_POST'submit'));
$sform->addElement($button_tray);
$sform->display();
?>


but nothing when i want to edit an article... i try it with wfsection but the same probleme

i would like to use koivi with all my module, could you help me ?

thanks for your help

PS: Sorry for my bad english but i'm french...

@+

2
samuels
Re: could you help me with koivi editor ?
  • 2004/11/24 13:07

  • samuels

  • Quite a regular

  • Posts: 249

  • Since: 2003/10/30


What version of news are you using?

3
assniok
Re: could you help me with koivi editor ?
  • 2004/11/24 13:11

  • assniok

  • Just popping in

  • Posts: 15

  • Since: 2002/9/13


it's the 1.1 why ?

@+

4
samuels
Re: could you help me with koivi editor ?
  • 2004/11/24 13:32

  • samuels

  • Quite a regular

  • Posts: 249

  • Since: 2003/10/30


News 1.1 version has two storyform.inc.php

You forgot edit modules/news/admin/storyform.inc.php

You must change this code:
echo "</p><p><b>"._AM_INTROTEXT."</b><br /><br />n";
xoopsCodeTarea("hometext"6015);
xoopsSmilies("hometext");

echo 
"<br /></p><p><b>"._AM_EXTEXT."</b><br /><br />n";
xoopsCodeTarea("bodytext"60152);
xoopsSmilies("bodytext");


With this:
echo "</p><p><b>"._AM_INTROTEXT."</b><br /><br />n";
//xoopsCodeTarea("hometext", 60, 15);
//xoopsSmilies("hometext");
include_once XOOPS_ROOT_PATH."/class/xoopsformloader.php";
include_once 
XOOPS_ROOT_PATH."/class/wysiwyg/formwysiwygtextarea.php";

$wysiwygHomeText= new XoopsFormWysiwygTextArea(''"hometext"$hometext'100%''400px','');
echo 
$wysiwygHomeText->render();


echo 
"<br /></p><p><b>"._AM_EXTEXT."</b><br /><br />n";
//xoopsCodeTarea("bodytext", 60, 15, 2);
//xoopsSmilies("bodytext");
$wysiwygBodyText= new XoopsFormWysiwygTextArea(''"bodytext"$bodytext'100%''400px','');
echo 
$wysiwygBodyText->render();


I hope it will help you.

5
assniok
Re: could you help me with koivi editor ?
  • 2004/11/24 13:40

  • assniok

  • Just popping in

  • Posts: 15

  • Since: 2002/9/13


thanks for your help, i try you answer

but, news 1.1 isn't the last version ?? where is the new version ??

thanks

@+

6
siweb
Re: could you help me with koivi editor ?
  • 2004/11/24 14:01

  • siweb

  • Not too shy to talk

  • Posts: 150

  • Since: 2004/5/2 1


You can find version 1.2.1 here.

7
assniok
Re: could you help me with koivi editor ?
  • 2004/11/24 14:17

  • assniok

  • Just popping in

  • Posts: 15

  • Since: 2002/9/13


thanks

and is it possible to use koivi editor for all modules ? or i must modify all modules for this ?

@+

8
assniok
Re: could you help me with koivi editor ?
  • 2004/11/24 14:31

  • assniok

  • Just popping in

  • Posts: 15

  • Since: 2002/9/13


it's ok for news module, but i have the same problem with wfsection beta 2.0.7 modules :(

an idea ?
thanks for advance for your help and @+

9
irmtfan
Re: could you help me with koivi editor ?
  • 2004/11/24 14:32

  • irmtfan

  • Module Developer

  • Posts: 3419

  • Since: 2003/12/7


great editor and i want use this one in my forums
i have some qestions:
1- how can i add more font to this for example "Tahoma" and how can i change default font to another font for example " Tahoma"

2- how can i change the default direction form left to right to right to left

3- i want in newbb2 use this editor by default for all users instead of DHTML and any user can change to DHML if want that one. so how can i do this
thanks a lot

10
samuels
Re: could you help me with koivi editor ?
  • 2004/11/24 21:22

  • samuels

  • Quite a regular

  • Posts: 249

  • Since: 2003/10/30


1.For adding new fonts you must use the editor methods, for example:

$wysiwyg_text_area= new XoopsFormWysiwygTextArea(_MD_CONTENTC'content2'$value'100%''400px','');
$wysiwyg_text_area->setFonts(array('Courier New'=>'Courier New, Courier, monospace','MS Serif'=>'MS Serif, New York, serif','Verdana'=>'Verdana, Geneva, Arial, Helvetica, sans-serif','Tahoma'=>'Tahoma'));
$sform->addElement$wysiwyg_text_area );


2.Right to left I think is only supported under iexplore, i¡ll try to add this on next bugfix version.

3.I have no idea how to select a default editor on newbb.

Login

Who's Online

199 user(s) are online (153 user(s) are browsing Support Forums)


Members: 0


Guests: 199


more...

Donat-O-Meter

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

Latest GitHub Commits