1
0
mirror of https://github.com/mbirth/wiki.git synced 2024-09-19 06:23:25 +01:00
wiki.mbirth.de/know-how/software/eclipse/_posts/2009-02-08-ezpublish-templates-in-eclipse.md

2.4 KiB

created language layout layout_old redirect_to tags title toc updated
2008-07-15 23:43:57 +0200 en redirect default https://blog.mbirth.de/archives/2008/07/15/ezpublish-templates-in-eclipse.html
know-how
software
ezpublish
eZPublish templates in Eclipse false 2009-02-08 14:37:49 +0100

Syntax-highlighting and Code-completion

With the Smile eZ Publish-plugin for Eclipse, there is syntax highlighting and code-completion for eZ Publish-templates. But this only works if you open the .tpl-files out of a project.

If not already set, at the configuration page *Window → Preferences… → General → Editors → File Associations → .tpl select Open With… → Smile TPL Editor. Alternatively you can use the JAC eZ Template Editor which is included in that plugin.

Installation:

  1. Help → Software Updates → Find and Install…
  2. (X) Search for new features to install
  3. Click Next >
  4. New Remote Site…
  5. Name: Smile ezPublish
  6. URL: http://smile-ez-plugin.sourceforge.net/update/
  7. Click OK
  8. make sure that the new entry is checked
  9. below: Finish
  10. install the plugin as usual

Template-validating and Class-browser

To get these features you have to download the Smile eZ Publish Extension and install it into eZ Publish. Enable the extension smileclasses at the eZ-Adminpanel.

In Eclipse, go to your project settings, open the page eZ Publish and at Server enter the URL to the smileclasses-export, e.g. http://foobar.com/ezpublish/smileclasses/export. Web root might be the local filepath to the main directory of the server (don't know if this is used, it isn't mentioned in any documentation). You might also enable the template validation.

If everything is correct, at Window → Show View → Other… → Smile eZ Publish you can activate the Classes View to see all eZ Publish-classes.

Note: On sites with RequireUserLogin=true you have to add both smileclasses-functions to the AnonymousAccessList[]. (see here).