Differences between revisions 10 and 11
Revision 10 as of 2012-01-28 07:42:07
Size: 4235
Comment:
Revision 11 as of 2012-01-28 08:01:30
Size: 4268
Comment:
Deletions are marked like this. Additions are marked like this.
Line 38: Line 38:
 * Unpack the attached [[attachment:tinymce3patch.zip]] mentioned above in  * Download and unpack [[http://www.svn.4sengines.eu/modcontrib/TinyMCE/trunk/patches/3.x-pre-lenya-2.0.4/tinymce3patch.zip|tinymce3patch.zip]] in
Line 58: Line 58:
 . as shown by the attached diff output: [[attachment:tinymce_sitemap.patch]] .  . as shown by the attached diff output:

HowTo Install TinyMCE 3.x in Lenya 2.0.X

General remarks

  • TinyMCE will not work if uploads are disabled. So either you set uploads.enable in local.build.properties, or you modify the
  • build/lenya/webapp/WEB-INF/web.xml
  • file as follows
  • <init-param>

    • <param-name>enable-uploads</param-name> <param-value>true</param-value>

    </init-param>

  • and restart lenya.
  • The TinyMCE 3.x API is different from the 2.x API. For that reason, all plugins have to be rewritten. There is some information in the Migration Guide.

  • A patch is appended to this page (see installation intructions below)

Basic Installation

  • Get the TinyMCE Main package and Language packs from the Download page.

  • If you upgrade from tiny 2.x, make sure to delete all old files before installing.
  • Unpack the main package in
  • ..../modules/tinymce/resources/
  • Unpack the language packs in
  • ..../modules/tinymce/resources/tinymce/jscripts/tiny_mce/
  • Important: this is different from Tiny 2.x, where you unpack them at the higher level!

If your version of Lenya is older than 2.0.4, you also need to:

  • Download and unpack tinymce3patch.zip in

  • ..../modules/tinymce/resources/
  • Important: This patch overwrites some files in the tinymce/jscripts/tiny_mce/plugins subtree; if you want to go back to TinyMCE 2.x, you need to backup this subtree first.

  • Modify the file
  • ..../modules/tinymce/resources/javascript/tiny_config.js
  • by adding the following line to the list of configuration options:
    • popup_css_add : "../modules/tinymce/css/lenya_dialog.css",

  • (This will make images and tables comply with the html strict schema, by showing only allowed attributes in the image and table popups.)
  • (Optional but recommended) Modify the file
  • ..../modules/tinymce/sitemap.xmap
  • as shown by the attached diff output:
  • Index: src/modules/tinymce/sitemap.xmap
    ===================================================================
    --- src/modules/tinymce/sitemap.xmap    (revision 1024205)
    +++ src/modules/tinymce/sitemap.xmap    (working copy)
    @@ -75,7 +75,7 @@
                 <!-- Check for language pack to render TinyMCE according to the 
                      requested locale. If it does not exist, fall back to English. --> 
                 <map:select type="resource-exists">
    -              <map:when test="fallback://lenya/modules/tinymce/resources/tinymce/jscripts/tiny_mce/langs/{request:locale}.js">
    +              <map:when test="fallback://lenya/modules/tinymce/resources/tinymce/jscripts/tiny_mce/langs/{request:locale/language}.js">
                     <map:transform src="fallback://lenya/modules/tinymce/xslt/page2edit.xsl">
                       <!-- the proxy path is set manually, since the document has already been
                            though the proxy transformer in the publication sitemap, and we can't
    @@ -84,7 +84,7 @@
                       <map:parameter name="continuationId" value="{flow-continuation:id}"/>
                       <map:parameter name="usecaseName" value="{request-param:lenya.usecase}"/>
                       <map:parameter name="publicationId" value="{page-envelope:publication-id}"/>
    -                  <map:parameter name="locale" value="{request:locale}"/>
    +                  <map:parameter name="locale" value="{request:locale/language}"/>
                       <map:parameter name="content" value="{request-param:tinymce.content}"/>
                     </map:transform>
                   </map:when>
    @@ -95,6 +95,7 @@
                       <map:parameter name="usecaseName" value="{request-param:lenya.usecase}"/>
                       <map:parameter name="publicationId" value="{page-envelope:publication-id}"/>
                       <map:parameter name="locale" value="en"/>
    +                  <map:parameter name="content" value="{request-param:tinymce.content}"/>
                     </map:transform>
                   </map:otherwise>
                 </map:select>

HowToInstallTinyMCE3.x (last edited 2012-01-28 08:01:30 by RainerSchoepf)