AnsweredAssumed Answered

Problem with TemplateService loading a .ftl from classpath

Question asked by alr on Mar 4, 2009
Latest reply on Dec 15, 2009 by jurevert
Hi all,

I am having a problem, when trying to load a presentation template from my classpath instead of putting it into the "/Company Home/" Directory (by using names of course then). The ClassPathRepoTemplateLoader does not get involved in any way. Somehow the file I am referencing to, gets a NodeRef (I do not know where from) when taking a look into the code with the debugger.

I am calling the following URL
http://localhost:8080/alfresco/template/?templatePath=render_block.ftl&contextPath=/Company%20Home/User%20Homes/SomeTenant/foo.file

I put the "render_block.ftl" template into an additional jar file (lying around in the exploded war) inside the "alfresco/extension/templates" directory of the jar - implying that the ClassPathRepoTemplateLoader  should get involved.
When using the eclipse debugger I found out that there is no involvement of the class whatsoever.

Can anyone shed some light on which templatePath I should use in this case or whether there is actually a bug. I would love to have all files inside a jar instead of putting them inside the repository (easy to replace and upgrade).

Any hints greatly appreciated.


–Alexander

Outcomes