[opencms-dev] Taglib OpenCms 8 suggestion

Sandrine Prousteau s.prousteau at eurelis.com
Thu May 31 11:54:47 CEST 2012


Hi all!
This message is to suggest additional macros in the tag <cms:info .../>

I use this one : <cms:info property="opencms.title" />, it works well!
I understand that , in case of detailed view of items, it get the mapped-to-url field value (and if there is none, the property value as usual), so the value is localizable.
But how can I get the meta Description and Keywords values??
In template3, we have a basic <cms:property name="Description" file="search" default="" />, that is not localized in case of shared items of detailed pages.

My suggestion is to do the same with other SEO data : 
	A mapped-to-metadescription field, with <cms:info property="opencms.metadescription" />
	A mapped-to-metakeywords field, with <cms:info property="opencms.metakeywords" />

Another suggestion:
I often use a tree of pages, in which I put an article in the "main" container (the main column for example). My articles are stored in /.content/contents/articles/. Currently, with <cms:info property="opencms.title" />, I must add meta properties on my page, after having edited my article resource. But meta data are related to the main content, not to the page!!! If I want to switch the article with another, I must re-edit the page properties... 
The idea is that it would be great if the tag could have the possibility, before reading the detailed-page-item or the page-properties, to read "a particular element of a particular container" (as for detailed-page-item). We should then set new parameters in the tag : container name to read, and type of the element in this container (we could say it read the first element found matching to a list of types, because we often have several "main" types - articles , forms, search elements... - ).

Obviously, I can create my own taglib... But the idea can be shared to all!
:)




More information about the opencms-dev mailing list