In this blog, I am going to share a very interesting point related to the allowedPaths property.
If you create your project and in this project you create a template and want to create a page using this template, your template will not visible in thesiteadmin . But if you copy the same template and paste in the geomtrixx /templates then this template will show you under geometrixx page at siteadmin page creation dialog.
So, the question arises here that why this template visibl e in geometrixx and why not visible in our project?
Theanswer is that geometrixx top level page has a cq : allowedTemplates property as shown below-
So because of this property all templates which are createdin geomtrixx project will be visible but our template has no restrictive (allowedPaths , allowedTemplate etc.) property.
So for making visible this template we have to addallowedPaths property. This is mandatory for the first or top level page creation. Now when we create any page under this page, all siblings templates of this template will be visible.
When we add this property, then this template will be visible as displayed below-
At the top level page we can addcq : allowedTemplates property so that we can see under this page only those templates which we defined in this property.
To show our template under /content directory or every page under /content directory , we have to add a property on our template named as allowedPaths = /content( /. *)?
In my case I created a template named ashomePage with the property allowedPaths = /content( /. *)?
Now this template will show on every page under content directory exceptgeometrixx page.
Be happy
If you create your project and in this project you create a template and want to create a page using this template, your template will not visible in the
So, the question arises here that why this templa
The
So because of this property all templates which are created
So for making visible this template we have to add
When we add this property, then this template will be visible as displayed below-
At the top level page we can add
To show our template under /content directory or every page under /
In my case I created a template named as
Now this template will show on every page under content directory except
Be happy



No comments:
Post a Comment