Etomite Community Forums: Here's My Fckeditor 2.2 + Etomite 0.6.1. Rtm Howto - Etomite Community Forums

Jump to content

  • (2 Pages)
  • +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

Here's My Fckeditor 2.2 + Etomite 0.6.1. Rtm Howto Implementing FCK2.2 with Etomite 061 RTM

#1 User is offline   Pelleke 

  • Etomite Forum Fan
  • Pip
  • Group: Member
  • Posts: 58
  • Joined: 10-October 05
  • Location:Voorburg - Netherlands
  • Interests:Classical- and jazz-Music (Conservatory student speaking), recording, Software development, webdevelopment.

Posted 26 January 2006 - 06:14 PM

Dear people!

I see everyone struggling around with FCKEditor which is partly supported by etomite, but not completely, and not included as well. This gives some problems for some of you.

Apart from that: Etomite as well as FCKEditor are improving fast, and coming up with new releases very frequently. This may make things a little complicated, and that is where I wrote this howto. Please reply with your comments, appreciations or questions when you try this!

NOTE: This HOWTO will not give you a working combination in either an older version of Etomite or an older version of FCKeditor. Make sure that you have the latest versions! (well... they were the latest versions at the moment I wrote this article)

HOW TO IMPLEMENT FCKEDITOR 2.2 IN ETOMITE 0.6.1 RTM.

Integrating FCKEditor 2.2 into Etomite 0.6.1 RTM

1. Download the FCKEditor package from http://www.fckeditor.net

2. Extract the package to your local computer

3. Rename the folder FCKeditor to fckeditor (read: remove the capitals)

4. Upload the fckeditor-folder to your manager/media folder

5. Make the following edits in manager/media/fckeditor/fckconfig.js

a. Look up the lines similar to these two, and set their values to php, just like this:

var _FileBrowserLanguage	= 'php';	// asp | aspx | cfm | lasso | perl | php | py
var _QuickUploadLanguage	= 'php';	// asp | aspx | cfm | lasso | php



b. I switched off the flash-browser and the link-browser. I don't need them, but if you do, read the bottom appendix of this howto. So for now: set them to false. (Find the lines similar to the ones below, and set them to false.)

FCKConfig.LinkBrowser = false;
...
FCKConfig.FlashBrowser = false;



c. Switch off all the upload-functions; uploading will be handled whitin the serverbrowser-window. (This because of Etomite's assets-folder system)

FCKConfig.LinkUpload = false;
...
FCKConfig.ImageUpload = false;
...
FCKConfig.FlashUpload = false;



6. Make the following edits in manager/media/fckeditor/editor/filemanager/browser/default/connectors/php/config.php

a. Switch the browser on :) (Find this line, and set the value to 'true')

$Config['Enabled'] = true;



b. Set the UserFilesPath

// Path to user files relative to the document root, patched in a universal way.
$Config['UserFilesPath'] = $ETOMITE_PAGE_BASE['relative'].'/[MySite]/assets/';


Note: Edited by Ralph to use $ETOMITE_PAGE_BASE['relative'] as assigned in the manager/includes/config.inc.php file for handling relative paths automatically.

Note: Edited by pelleke to use [MySite] for taking care of cases where Etomite is not installed in the document root. Thanks to Tony Benci (tbenci)


7. We should fix some things in manager/actions/dynamic/mutate_content.dynamic.action.php. Open the file.

a. Find the line containing the following comment:
# Start - FCKeditor
(In my case it turned out to be line 430, so it should be somewhere there.) One or a few lines below, you find a line containing the text:

prepContent();


DELETE this line. This command is depricated, and will give you an error.


b. A few lines below the in step 7a deleted line, you will find a line that should be patched in the following way:

Original line:
$oFCKeditor->Value = $newcontent;

Patched line:
$oFCKeditor->Value = $content['content'];



c. The default heigth of an FCKeditor instance is 200px, this turns out to be rather small for page editing in Etomite. If you want to raise this to 400px (which I recommend you) write the following line above the line you just patched in step 7B

$oFCKeditor->Height = '400';



8. Now we should make some other patches to make the imagebrowser work well. Make sure you don't miss one!

a. Look up this line in manager/media/fckeditor/fckconfig.js and replace 'Type=Image' by 'Type=images'

Original line:
FCKConfig.ImageBrowserURL = FCKConfig.BasePath + 'filemanager/browser/default/browser.html?Type=Image&Connector=connectors/' + _FileBrowserLanguage + '/connector.' + _FileBrowserExtension;

Our patched line:
FCKConfig.ImageBrowserURL = FCKConfig.BasePath + 'filemanager/browser/default/browser.html?Type=images&Connector=connectors/' + _FileBrowserLanguage + '/connector.' + _FileBrowserExtension;



b. Look up this line in manager/media/fckeditor/editor/filemanager/browser/default/frmresourcetype.html and patch it like this:

Original line:
['Image','Image'],


Our patched line:
['images','Image'],



c. Look up these two lines in manager/media/fckeditor/editor/filemanager/browser/default/connectors/php/config.php and patch them in a similar way:

Original lines:
$Config['AllowedExtensions']['Image']	= array('jpg','gif','jpeg','png');
$Config['DeniedExtensions']['Image']	= array();

Our patched lines:
$Config['AllowedExtensions']['images']	= array('jpg','gif','jpeg','png');
$Config['DeniedExtensions']['images']	= array();



d. Look up this line in manager/media/fckeditor/editor/filemanager/browser/default/connectors/php/connector.php and patch it also like this:

Original line:
if ( !in_array( $sResourceType, array('File','Image','Flash','Media') ) )

Our patched line:
if ( !in_array( $sResourceType, array('File','images','Flash','Media') ) )



9. Make sure (with your FTP-client) that the folder assets/images is chmodded to 777. (In a valid etomite-installation this should already be the case.)

10. Go to your etomite manager, and select the FCKeditor in your Interface&Editor Settings in the Etomite Configuration.

... And then you should have a working FCKeditor 2.2 with Etomite 0.6.1 RTM with a working image-browser and upload-function! Happy FCKing!

Appendix:
If you also plan to use the flash-browser and/or the link-browser (which I wanted you to disable in step 5b), you should take care of creating the folders. This is rather easy, but quite annoying if you forget it.

1. Switch on these functions again by setting their properties (back) to true. (Look at step 5b)

2. in the asset/ -folder, create a folder named 'Flash' and chmod it to 777. Create another folder named File and also chmod it to 777. (If you plan to use only one of these browser-functions, you need only one folder of course. :))

This post has been edited by pelleke: 18 April 2006 - 10:07 AM


#2 User is offline   Ralph 

  • Etomite Administrator
  • Group: Admin
  • Posts: 6,418
  • Joined: 01-July 04
  • Gender:Male
  • Location:Jamestown, NY USA
  • Interests:Computers, Camping, Hiking, Aviation

Posted 26 January 2006 - 07:05 PM

Good work, pelleke... This should be a good starter for those desiring or requiring FCKeditor for document editing...

As members will notice, FCKeditor is not a Plug-N-Play editor... I have tested this installation guide and it does work as described... I made one minor change, however, which makes it easier for FCKeditor to locate the assets/images/ directory... I have also attached a tar.gz of the modified code as it functions on my development site... At some point Dean will most likely move this download to the Etomite Resources site... Now all that is required is modification of the manager/actions/dynamic/mutate_settings.dynamic.action.php file to allow for configuration changes for the editor... :eto:

Attached File(s)



#3 User is offline   Pelleke 

  • Etomite Forum Fan
  • Pip
  • Group: Member
  • Posts: 58
  • Joined: 10-October 05
  • Location:Voorburg - Netherlands
  • Interests:Classical- and jazz-Music (Conservatory student speaking), recording, Software development, webdevelopment.

Posted 26 January 2006 - 07:27 PM

Hey!

Your fix is OK to me, but it has one little disadvantage: it is not possible any more to use fck outside etomite... I think for almost everyone this will not be a problem though. By the way: I don't know the etomite-insides this well to know these tricks ;)

//offtopic
I didn't even know about the existence of a etomite resources site! Is that the etomite-resources.com site? (which actually doesn't work here right now, guess because of those server problems)
Then I really have to take a look there...
// /

This post has been edited by pelleke: 26 January 2006 - 07:30 PM


#4 User is offline   Ralph 

  • Etomite Administrator
  • Group: Admin
  • Posts: 6,418
  • Joined: 01-July 04
  • Gender:Male
  • Location:Jamestown, NY USA
  • Interests:Computers, Camping, Hiking, Aviation

Posted 26 January 2006 - 07:34 PM

pelleke, on Jan 26 2006, 03:27 PM, said:

Hey!

Your fix is OK to me, but it has one little disadvantage: it is not possible any more to use fck outside etomite... I think for almost everyone this will not be a problem though. By the way: I don't know the etomite-insides this well to know these tricks ;)

//offtopic
I didn't even know about the existence of a etomite resources site! Is that the etomite-resources.com site? (which actually doesn't work here right now, guess because of those server problems)
Then I really have to take a look there...
// /

I'm not sure how many people would use FCKeditor, located within the Etomite install, from outside Etomite... Who would use anyting but Etomite... :lol:
Yes, the etomite-resources.com site will have additional Etomite addons and such... Unfortunately, Dean has been having problems keeping the site online over the past several days... I'm sure he'll have the problems resolved soon... B)

#5 User is offline   Pelleke 

  • Etomite Forum Fan
  • Pip
  • Group: Member
  • Posts: 58
  • Joined: 10-October 05
  • Location:Voorburg - Netherlands
  • Interests:Classical- and jazz-Music (Conservatory student speaking), recording, Software development, webdevelopment.

Posted 18 April 2006 - 10:09 AM

Added '[mysite]' in step 6B, thanks to Tony Benci. (Is it actually correct? Does it always work with these amount of slashes, even when etomite IS installed in the document root? Is there somebody who can test that for me?)

This post has been edited by pelleke: 18 April 2006 - 10:09 AM


#6 User is offline   DeanC 

  • Etomite Administrator
  • Group: Admin
  • Posts: 4,722
  • Joined: 08-June 04
  • Gender:Male
  • Location:United Kingdom

Posted 18 April 2006 - 11:35 AM

If you are using 061, you do not need to do all of this as we have released an FCKEditor package for it on the downloads page.

#7 Guest_paulg_*

  • Group: Guests

Posted 21 April 2006 - 03:19 PM

Did this a couple of days ago - and all hunky dory - in Firefox. Also made the mod described elsewhere to use Xinha inage browser. All fine.

Just checked it in IE (as my users will all be using ie) and fckedit displays no toolbar at all. Any ideas

Thanks

Paul

#8 User is offline   intramanga 

  • Etomite Forum Newbie
  • Group: Member
  • Posts: 6
  • Joined: 09-June 05

Posted 08 June 2006 - 08:03 PM

View Postpaulg, on Apr 21 2006, 05:19 PM, said:

Did this a couple of days ago - and all hunky dory - in Firefox. Also made the mod described elsewhere to use Xinha inage browser. All fine.

Just checked it in IE (as my users will all be using ie) and fckedit displays no toolbar at all. Any ideas

Thanks

Paul



Same problem here , no toolbars in IE :(

Ed,

#9 User is offline   nalagar 

  • Likes Etomite Forums!
  • PipPip
  • Group: Member
  • Posts: 172
  • Joined: 28-September 05
  • Location:Sweden
  • Interests:Programming, graphic design, swimming, gym, writing music.

Posted 08 June 2006 - 10:13 PM

Make sure that you don't have any extra commas or other errors in the code that defines the toolbar list. I know the downloadable FCK-package for Etomite had this error. I wrote View Post
Same problem here , no toolbars in IE :(

Ed,[/quote]

#10 User is offline   vampke 

  • Likes Etomite Forums!
  • PipPip
  • Group: Member
  • Posts: 151
  • Joined: 19-August 05

Posted 09 October 2006 - 12:03 PM

Hey guys,

I have a problem with this. I changed everything and double checked, but if I try to include an image using the image browser, I get the empty folder 'Image' instead of the sites folder.
How come?

#11 User is offline   Psycho Mantis 

  • Etomite Forum Fan
  • Pip
  • Group: Member
  • Posts: 113
  • Joined: 29-May 05
  • Location:Germany

Posted 14 December 2006 - 02:14 PM

vampke, I have the same problem.

The image browser doesn't work.

#12 User is offline   Psycho Mantis 

  • Etomite Forum Fan
  • Pip
  • Group: Member
  • Posts: 113
  • Joined: 29-May 05
  • Location:Germany

Posted 09 January 2007 - 01:09 PM

I checked my config file again and noticed one funny thing.
While the image filemanager remains emtpy, if I click "Create New Folder" in the manager, the folder is actually created in the correct location.
Unfortunately, I can't see it (or any other files in the images folder).

Any ideas?

(Etomite 0.6.1.3)

This post has been edited by Psycho Mantis: 09 January 2007 - 01:09 PM


#13 User is offline   Ralph 

  • Etomite Administrator
  • Group: Admin
  • Posts: 6,418
  • Joined: 01-July 04
  • Gender:Male
  • Location:Jamestown, NY USA
  • Interests:Computers, Camping, Hiking, Aviation

Posted 09 January 2007 - 02:14 PM

View PostPsycho Mantis, on Jan 9 2007, 08:09 AM, said:

I checked my config file again and noticed one funny thing.
While the image filemanager remains emtpy, if I click "Create New Folder" in the manager, the folder is actually created in the correct location.
Unfortunately, I can't see it (or any other files in the images folder).

Any ideas?

(Etomite 0.6.1.3)

Does the folder appear on subsequent openings of the image manager...???

#14 User is offline   DeanC 

  • Etomite Administrator
  • Group: Admin
  • Posts: 4,722
  • Joined: 08-June 04
  • Gender:Male
  • Location:United Kingdom

Posted 09 January 2007 - 02:15 PM

Remember Ralph, that this isnt an issue with the Eto install of FCK - it's a user-upgrade that can't figure out.

#15 User is offline   Chris Fancy 

  • Etomite Forum Fan
  • Pip
  • Group: Member
  • Posts: 115
  • Joined: 08-January 06
  • Location:Nelson, Lancs, UK

Posted 09 January 2007 - 05:40 PM

I have an issue with FCK Editor which may be related...

I have an install on a domain www.clientswebsite.co.uk/etomite/ and when i use FCK editor to create a pictures or a pictures directory it creates an assetts/images directory in the domain root and not in /etomite/assets/images/ and you can only see these images in the new directory from the FCKEditor...
and not the default /assets/images...

But, when I move the whole-site up one level from /Etomite to the domain root it then works fine and you can see the images inside /assets/images/ from FCKEditor image uploader. but not the directory you created earlier... you then need to move them accross...

Is it something to do with this issue or have i just got some other setting set wrong...?

Regards, and Happy New Year to all you Guy's... :P
Chris.

This post has been edited by Chris Fancy: 09 January 2007 - 05:42 PM


Share this topic:


  • (2 Pages)
  • +
  • 1
  • 2
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users