Here is a short description of how to make the "spaw"
WYSIWYG Online Editor work with phpCMS:
1) download SPAW PHP at SourceForge:
http://sourceforge.net/project/showfiles.php?
group_id=77954&release_id=171887
I'm using SPAW PHP v.1.0.3. on my site (Attention:
make sure to download the php and not the .NET
version of spaw!)
2) unpack the Spaw archive and copy the
directory "spaw" to the webserver into the phpCMS
directory (which is /parser in most installations).
3) configure Spaw as described in their installation doc
(installation of spaw is done by changing the value of a
a few variables in the
file /parser/spaw/spaw_control.config.php)
4) save the following short php-script under the
filename /parser/include/class.edit_wysiwyg_phpcms.php
on the webserver:
<?php
$sw = new SPAW_Wysiwyg($FIELD,$buffer,
'en','sidetable','default',
'100%','350px','');
$sw->show();
?>
locate in the file /parser/parser.php the lines:
case 'EDIT':
include
($PHPCMS_INCLUDEPATH.'/class.edit_phpcms.php');
break;
(about line 152) and add three lines of code so the
block looks like this:
case 'EDIT':
define('DR', $DEFAULTS->DOCUMENT_ROOT);
$spaw_root = DR.$DEFAULTS->SCRIPT_PATH.'/spaw/';
include $spaw_root."spaw_control.class.php";
include
($PHPCMS_INCLUDEPATH.'/class.edit_phpcms.php');
break;
(the three lines between "case 'EDIT'" and the last
include command were added)
That's all!
Now the WYSIWYG Online Editor can be used by
writing "WYSIWYG" as the edittype in the file templates:
{FIELDNAME EDITTYPE="WYSIWYG"}
Please take notice, that the spaw online editor only
works with the internet explorer! Users who try to edit a
page with a different editor will still get the normal
textbox instead (edittype="textarea")
ciao.. Iggi
Logged In: NO
Attention: This patch only works, if you have phpCMS 1.2.0
RC1 or later installed.
With phpCMS 1.2.0 Beta1, Beta2 or older Versions it won't
work!
ciao.. Iggi