Expand my Community achievements bar.

Extending Page Properties in AEM

Avatar

Community Advisor

11/29/22

blogs-banner.jpg

Extending Page Properties

  by Mayur Satav

Overview

It is always one of the prime requirements for the projects to extend page properties. It helps to manage metadata and many other functionalities associated with the page.In this blog we will see how to extend page properties.

 

MayurSatav_0-1669744865554.png

 

MayurSatav_1-1669744865607.png

 

MayurSatav_2-1669744865676.png

 

MayurSatav_3-1669744865677.png

 

MayurSatav_4-1669744865677.png

 

 
<newtab
    cq:showOnCreate="{Boolean}true"
    jcr:primaryType="nt:unstructured"
    jcr:title="New Tab"
    sling:resourceType="granite/ui/components/coral/foundation/fixedcolumns">
    <items jcr:primaryType="nt:unstructured">
        <column
            jcr:primaryType="nt:unstructured"
            sling:resourceType="granite/ui/components/coral/foundation/container">
            <items jcr:primaryType="nt:unstructured">
                <section
                    jcr:primaryType="nt:unstructured"
                    jcr:title="New Custom tab"
                    sling:resourceType="granite/ui/components/coral/foundation/form/fieldset">
                    <items jcr:primaryType="nt:unstructured">
                        <textfield
                            jcr:primaryType="nt:unstructured"
                            sling:resourceType="granite/ui/components/coral/foundation/form/textfield"
                            name="./testfield"/>
                    </items>
                </section>
            </items>
        </column>
    </items>
</newtab>
 
MayurSatav_5-1669744865675.png

 

 

Q&A

Please use this thread to ask questions relating to this article

5 Comments

Avatar

Administrator

11/29/22

@MayurSatav Thank you for sharing this with the community. I have seen this use case had been asked many times in the past. I hope your article helps those who are looking to extend page properties. 

Avatar

Adobe Champion

12/6/22

Agree with @kautuk_sahni, this comes up as a question a number of times. Thank you @MayurSatav.

Avatar

Level 2

3/9/23

Thanks for the article @MayurSatav 
I'm currently trying to figure out how to access a custom page property from a custom component in the html file with data-sly-test. It would be great if you could share a your ideas how this can be done. Thanks!

Avatar

Level 2

3/9/23

@MayurSatav I figured it out myself. It works for my like this: ${currentPage.Properties.fieldName} It was previously not working because of an issue with the checkbox in the properties.