Refresh Page when edit component | Community
Skip to main content
Level 3
Feb 7, 2019 2:26 PM UTC
Solved

Refresh Page when edit component

Hi Guys,

I was using the Adobe AEM 6.4 and I'm including a component using the code below.

<sly data-sly-resource="${'menu_vertical' @ resourceType='ATT/components/content/menu_vertical',decorationTagName='div',cssClassName='att-componentheight'}"/>

But I put editConfigListener on the component to refresh the page when editing the component. But it doesn't work.

<?xml version="1.0" encoding="UTF-8"?>

<jcr:root xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0"

    jcr:primaryType="cq:EditConfig">

    <cq:listeners

        jcr:primaryType="cq:EditListenersConfig"

        afteredit="REFRESH_PAGE"/>

</jcr:root>

Any suggestion?

Thanks a lot.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
arunpatidar
arunpatidarAccepted solution
New Participant
Feb 7, 2019 2:32 PM UTC

Hi,

It actually refresh the inter frame doesn't do parent reload.

you can force refresh by adding below script of category cq.authoring.dialog

(function ($, $document) {

    "use strict";

    $document.on("dialog-success", function() {

window.location.reload();

})($, $(document));

Arun Patidar

2 replies

Level 3
Feb 7, 2019 2:48 PM UTC

Thanks, arunpatidar26

Translate
arunpatidar
arunpatidarAccepted solution
New Participant
Feb 7, 2019 2:32 PM UTC

Hi,

It actually refresh the inter frame doesn't do parent reload.

you can force refresh by adding below script of category cq.authoring.dialog

(function ($, $document) {

    "use strict";

    $document.on("dialog-success", function() {

window.location.reload();

})($, $(document));

Translate
Arun Patidar