What is the best way to refresh the extension panel after the remote HTML page was updated ?

New Here ,
Dec 30, 2020

Copy link to clipboard

Copied

The Premiere Panel extension I built is hosting a HTML page in an iframe.
This page is located on my server and every once in a while I'm updating the HTML page with new features or bug fixes.
I want to request the users to refresh the panel when there is an updated version in my cloud, to avoid the schnario of old page related errors for users that are not closing and reopening the PPro for a long time.

One way to solve it can be using long polling to my server with the current HTML version but I wonder if there is a better solution.
 

Perhaps your panel could check for new HTML once every N minutes; when an update is available, turn the panel background red (or something), and offer an "update" button as appropriate...

TOPICS
How to, SDK

Views

59

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

What is the best way to refresh the extension panel after the remote HTML page was updated ?

New Here ,
Dec 30, 2020

Copy link to clipboard

Copied

The Premiere Panel extension I built is hosting a HTML page in an iframe.
This page is located on my server and every once in a while I'm updating the HTML page with new features or bug fixes.
I want to request the users to refresh the panel when there is an updated version in my cloud, to avoid the schnario of old page related errors for users that are not closing and reopening the PPro for a long time.

One way to solve it can be using long polling to my server with the current HTML version but I wonder if there is a better solution.
 

Perhaps your panel could check for new HTML once every N minutes; when an update is available, turn the panel background red (or something), and offer an "update" button as appropriate...

TOPICS
How to, SDK

Views

60

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Dec 30, 2020 0
Adobe Employee ,
Dec 30, 2020

Copy link to clipboard

Copied

You say 'every once in a while'; is it not enough, to refresh the panel's contents each time the panel is opened? 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 30, 2020 0
New Here ,
Dec 30, 2020

Copy link to clipboard

Copied

Thank you Bruce Bullis for reply.

The way it's work is like that, I'm updateing the HTML file once a week approx.  Some of the clients that are working with the PPro leave it open all the time so I don't get a chance to update the content, I need a way to notify them that they are runnig an old version of the panel and that they need a refresh.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 30, 2020 0
Adobe Employee ,
Dec 30, 2020

Copy link to clipboard

Copied

Perhaps your panel could check for new HTML once every N minutes; when an update is available, turn the panel background red (or something), and offer an "update" button as appropriate...

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Dec 30, 2020 1
Elad5EAF LATEST
New Here ,
Jan 11, 2021

Copy link to clipboard

Copied

The solution that worked for me was to compare the html version to the html version in the server when the panel get focus.
The inspration came from this thread.

<head>

    <script>

        window.onfocus = () => {console.log("FOCUSED!");};

        window.onblur = () => {console.log("BLURRED!");};

    </script>

</head>

 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jan 11, 2021 0