Вопрос

I am setting up a Magnolia-based website and trying to place a template script into the templates folder in the webapp. However, I cannot find that folder anywhere. All tutorials say that, if I go to this directory magnolia-5.0/apache-tomcat-7.0.40/webapps/magnoliaAuthor in my enviroment, I can get it, but I haven't managed it.

I attach an screenshot of my magnoliaAuthor folder in which every folder that is supposed to be there actually is, except for the only one that I need (templates).

Hope you can help me with this. Thanks!enter image description here

Это было полезно?

Решение

What kind of template? If it is jsp, you can just place it anywhere you want in that folder and reference it from the template definition. If it is freemarker template, those are by default served from either the classpath or from repository, so for testing you can just upload it to the repo via templates app http://yourtomcat:port/magnoliaAuthor/.magnolia/admincentral#app:templatesApp:;

BTW if you install samples module (add magnolia-templating-samples.jar in your WEB-INF folder), it will create folder "templates" in your webapp and extract sample jsp templates in that folder.

HTH, Jan

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top