Skip to content Skip to navigation

fckeditor on Leland

Posted by: 
Topics: 

Configuring fckeditor to run on Leland
 
The fckeditor is a very powerful user tool for creating and editing site content. The requirement for Drupal to run in the cgi-bin directory imposes special restrictions on the use of XML files for the editor templates and files to be attached to node and block content.
 
To make this work the XML files and files used as node content must be placed outside of the cgi-bin directory. XML files in the cgi-bin directory are not served correctly. All fckeditor files are stored in the same directory. Some file types do not execute correctly from the cgi-bin.
 
To solve these problems we have moved the xml files and the fckeditor files to the web root /WWW/. ( /WWW/drupal_files/ and /WWW/drupal_xml/)
 

  1. Fckeditor uses : /fckeditor/fckeditor/editor/filemanager/connector/php/config.php to point to the location of the files:
    1. // Path to user files relative to the document root.
      $Config['UserFilesPath'] = '/dept_group/dept_group_name/drupal_files/' ;
    2. //  Path to absolute disk address. Both point to same location. $Config['UserFilesAbsolutePath']/afs/ir/dept_group/dept_group_name/WWW/drupal_files/' ;
    3. Note: both paths must be set pointing to the same file. The relative based on the web address and the absolute based on the disk address.
    4. Under File Browser Setting of fckeditor profile set both the Path and the Absolute path to /drupal_files.
    5. In the config.php above set $Config['Enabled'] = FALSE; to TRUE.
    6. Full permission must be granted to cgi-bin on the drupal_files in the root.
    7. Login to the Leland server and cd to the site root/drupal_files.
    8. Find the name of the cgi-bin user using fs listacl. This will give the names of all the users and their access rights.
    9. For WWW: CD to the WWW and Execute: fs setacl . (cgi-bin user) l to give the cgi-bin user access to the folder.
    10. For the WWW/drupal_files Execute: fs setacl . (cgi-bin user) rlidwk to give full access to drupal_files.

Adjust and configure the fckeditor templates

  1. The file /modules/fckeditor/fckeditor/config.js. I points to the location of the xml files Ex: https://www.stanford.edu/dept_group/dept_group_name/drupal_xml/fckstyles.xml
    https://www.stanford.edu/dept_group/dept_group_name/drupal_xml/fcktemplates.xml
  2. XML files cannot execute in the cgi-bin so we put them in WWW/drupal_xml
  3. The template images go into /modules/fckeditor/fckeditor/editor/dialog/fck_template/images