Overloading of virtual pages in the classifieds tree structure


This feature is available from version 1.11.

General point on virtual pages: Overloading virtual pages

  1. Description
  2. Overloads
    1. Example

Description

In the classifieds tree, created from the "classifieds root" button, there are 2 types of virtual pages that can be overloaded: 

Overloads

Description

Overload file name

Default configuration file
( Ametys 4.9)

Default configuration file
( Ametys 4.8)

Intermediate pages in the classifieds tree

ugc.classified-ads.transitional.xml

<model template="ugc-transitional-page">
    <zone id="default"> 
        <service id="org.ametys.web.service.SitemapService">
            <parameters>
                <depth i18n="false">1</depth>
                <all i18n="false">false</all>
                <includeInvisiblePage i18n="false">true</includeInvisiblePage>
            </parameters>
        </service>
    </zone>
</model>
<model template="ugc-transitional-page">
    <zone id="default"> 
      <service id="org.ametys.web.service.SitemapService">
            <depth i18n="false">1</depth>
            <all i18n="false">false</all>
            <includeInvisiblePage i18n="false">true</includeInvisiblePage>
        </service>
    </zone>
</model>

Last-level pages in the classifieds tree structure

ugc.classified-ads.page.xml

<model template="ugc-page">
    <zone id="default"> 
        <content view="main"/>
    </zone>
</model>
<model template="ugc-page">
    <zone id="default"> 
        <content view="main"/>
    </zone>
</model>

Reminder: Overload files should therefore be named: ugc.classified-ads.transitional.xml for intermediate pages in the tree structure and ugc.classified-ads.page.xml for pages containing ads.

Example

Overloading of virtual classifieds pages (ugc.classified-ads.page. xml ) to add a Sitemap service above the classified ad content

<model template="page">     
   <zone id="default"> 
     <service id="org.ametys.web.service.SitemapService"> 
        <parameters>           
           <depth i18n="false">1</depth>             
           <all i18n="false">false</all>             
           <includeInvisiblePage i18n="false">true</includeInvisiblePage>     
        </parameters>   
     </service>         
     <content view="main"/>     
 </zone> 
</model>

 

Back to top

Classified Ads