<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Share extensibility with template in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/share-extensibility-with-template/m-p/258769#M211899</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;When you create your overridden document-details Template-Instance configuration file and the associated FreeMarker template file you could make use of the &amp;lt;@markup&amp;gt; directive which works in a similar way to the &amp;lt;@region&amp;gt; directive but is just used to demarcate specific sections of a template for extension (this directive is mentioned briefly at the end of this blog: &lt;/SPAN&gt;&lt;A href="http://blogs.alfresco.com/wp/ddraper/2011/08/12/customizing-alfresco-share-freemarker-templates/" rel="nofollow noopener noreferrer"&gt;http://blogs.alfresco.com/wp/ddraper/2011/08/12/customizing-alfresco-share-freemarker-templates/&lt;/A&gt;&lt;SPAN&gt;). This directive has the same actions ("before", "after", "remove", "replace") as the &amp;lt;@region&amp;gt; directive. If you can use this directive in your custom template and then define a new an extension module to change the default values and use an evaluator so that the changes only apply to certain sites.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Part of the problem with removing all the regions as you've suggested is that you'll still be left with the basic layout defined through the &amp;lt;div&amp;gt; elements containing the YUI grid-layout CSS classes. But if you wrap these elements with &amp;lt;@markup&amp;gt; directives then you'll have full control of the layout of the page.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;We not used too many &amp;lt;@markup&amp;gt; directives throughout the Share code-base yet because we weren't sure where they'd be useful. I'm hoping that we can start to introduce this directive more (along with others) to give complete control over the output of Share but I can't guarantee when this might happen.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Dave&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 06 Feb 2012 11:19:06 GMT</pubDate>
    <dc:creator>ddraper</dc:creator>
    <dc:date>2012-02-06T11:19:06Z</dc:date>
    <item>
      <title>Share extensibility with template</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/share-extensibility-with-template/m-p/258766#M211896</link>
      <description>Hello,while exploring the nice 4.x features for share extensibility - I would like to replace a page template for a specifc site only. From the blogs here http://blogs.alfresco.com/wp/ddraper/ and the docs here http://docs.alfresco.com/4.0/topic/com.alfresco.enterprise.doc/concepts/Share-Extensibili</description>
      <pubDate>Sun, 05 Feb 2012 12:58:19 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/share-extensibility-with-template/m-p/258766#M211896</guid>
      <dc:creator>lotharmärkle</dc:creator>
      <dc:date>2012-02-05T12:58:19Z</dc:date>
    </item>
    <item>
      <title>Re: Share extensibility with template</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/share-extensibility-with-template/m-p/258767#M211897</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I think that you have a couple of options here…&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Firstly you could override the Template-Instance definition for the document-details page (this is found in "share\WEB-INF\classes\alfresco\site-data\template-instances\document-details.xml") by defining your own TemplateInstance configuration file and placing it under the "web-extension" path, e.g. "share\WEB-INF\classes\alfresco\&lt;/SPAN&gt;&lt;STRONG&gt;web-extension&lt;/STRONG&gt;&lt;SPAN&gt;\site-data\template-instances" and then map to your own Template freemarker file.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This would give you complete flexibility over the template - however the the disadvantage with this approach would be that you would have to maintain the &amp;lt;region&amp;gt; definitions for all the &amp;lt;components&amp;gt; that you wish to keep. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The second option might be to investigate either adding in additional content via Sub-Components (see &lt;/SPAN&gt;&lt;A href="http://blogs.alfresco.com/wp/ddraper/2011/07/22/how-to-add-content-to-an-alfresco-share-page/" rel="nofollow noopener noreferrer"&gt;http://blogs.alfresco.com/wp/ddraper/2011/07/22/how-to-add-content-to-an-alfresco-share-page/&lt;/A&gt;&lt;SPAN&gt;) or by additional regions (&lt;/SPAN&gt;&lt;A href="http://blogs.alfresco.com/wp/ddraper/2011/08/12/customizing-alfresco-share-freemarker-templates/" rel="nofollow noopener noreferrer"&gt;http://blogs.alfresco.com/wp/ddraper/2011/08/12/customizing-alfresco-share-freemarker-templates/&lt;/A&gt;&lt;SPAN&gt;). The benefit of these approaches would be that you wouldn't need to keep you local Template in-sync with any changes made to the base template.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Unfortunately, looking at the content you're trying to modify you're somewhat limited by the use of the YUI grid CSS that is splitting the page into a 2/3 - 1/3 column split. It really depends on your exact design requirements for displaying the custom properties.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Dave&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Feb 2012 10:28:46 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/share-extensibility-with-template/m-p/258767#M211897</guid>
      <dc:creator>ddraper</dc:creator>
      <dc:date>2012-02-06T10:28:46Z</dc:date>
    </item>
    <item>
      <title>Re: Share extensibility with template</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/share-extensibility-with-template/m-p/258768#M211898</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thank you for your thoughts and suggestions on this.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So overriding via web-extension would allow to replace the template without touching the source file - great! I could add a switch and include the ootb template.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there a way to combine this with the extensibility mechanism, so that it would only be active based e.g. on the site name? All other sites would then still use the ootb template.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Another idea would be to remove all regions on the document-details using the extensibility mechanism with &amp;lt;@region action="remove"&amp;gt; and to replace/extend the last region of that document-details (custom-doclib) with the new template layout. But I am not sure if the before-removed-regions will be available…&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;All a litte complicated as I just would like to change the structure and placement of the regions on the page, not the region contents itself.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is this kind of customization on the extensinibilty mechanism roadmap? Maybe something like&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;template-customizations&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; &amp;lt;template-customization&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;targetPackageRoot&amp;gt;org.alfresco&amp;lt;/targetPackageRoot&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sourcePackageRoot&amp;gt;org.acme.templates&amp;lt;/sourcePackageRoot&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; &amp;lt;/template-customization&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;/template-customizations&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;which would mean that this will replace the template org.alfresco.document-details.ftl with org.acme.templates.document-details.ftl.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; lothar&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Feb 2012 11:01:07 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/share-extensibility-with-template/m-p/258768#M211898</guid>
      <dc:creator>lotharmärkle</dc:creator>
      <dc:date>2012-02-06T11:01:07Z</dc:date>
    </item>
    <item>
      <title>Re: Share extensibility with template</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/share-extensibility-with-template/m-p/258769#M211899</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;When you create your overridden document-details Template-Instance configuration file and the associated FreeMarker template file you could make use of the &amp;lt;@markup&amp;gt; directive which works in a similar way to the &amp;lt;@region&amp;gt; directive but is just used to demarcate specific sections of a template for extension (this directive is mentioned briefly at the end of this blog: &lt;/SPAN&gt;&lt;A href="http://blogs.alfresco.com/wp/ddraper/2011/08/12/customizing-alfresco-share-freemarker-templates/" rel="nofollow noopener noreferrer"&gt;http://blogs.alfresco.com/wp/ddraper/2011/08/12/customizing-alfresco-share-freemarker-templates/&lt;/A&gt;&lt;SPAN&gt;). This directive has the same actions ("before", "after", "remove", "replace") as the &amp;lt;@region&amp;gt; directive. If you can use this directive in your custom template and then define a new an extension module to change the default values and use an evaluator so that the changes only apply to certain sites.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Part of the problem with removing all the regions as you've suggested is that you'll still be left with the basic layout defined through the &amp;lt;div&amp;gt; elements containing the YUI grid-layout CSS classes. But if you wrap these elements with &amp;lt;@markup&amp;gt; directives then you'll have full control of the layout of the page.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;We not used too many &amp;lt;@markup&amp;gt; directives throughout the Share code-base yet because we weren't sure where they'd be useful. I'm hoping that we can start to introduce this directive more (along with others) to give complete control over the output of Share but I can't guarantee when this might happen.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Dave&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Feb 2012 11:19:06 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/share-extensibility-with-template/m-p/258769#M211899</guid>
      <dc:creator>ddraper</dc:creator>
      <dc:date>2012-02-06T11:19:06Z</dc:date>
    </item>
  </channel>
</rss>

