Page 1 of 2
Auto refresh
Posted: Thu Dec 17, 2015 1:59 pm
by TonyS
The user will submit a request via my app to an external management system. When the managers of the system quote the request parameters in the db will change and force the elements on the page to display or not depending on their values. However, the page will only check the service when the page is loaded. So my question is "how do it set a timed refresh of the page?"
Thanks
Auto refresh
Posted: Thu Dec 17, 2015 2:02 pm
by TonyS
Better still refresh just the data fed elements?
Auto refresh
Posted: Thu Dec 17, 2015 6:42 pm
by Serhii Kulibaba
Hello Tony,
Please use setInterval method for calling services: https://developer.mozilla.org/en-US/d...
Auto refresh
Posted: Fri Dec 18, 2015 10:26 am
by TonyS
Auto refresh
Posted: Sun Jun 19, 2016 4:22 am
by rabia batool
Can you please share example of how to refresh a page when there is new entry for a specific user in database collection?.
Auto refresh
Posted: Tue Jun 21, 2016 6:26 am
by Serhii Kulibaba
You don't need to refresh a page for that, just invoke the service or JS there.
Auto refresh
Posted: Tue Jun 21, 2016 5:07 pm
by rabia batool
i have already called message load service on page load and also when send button click.
Auto refresh
Posted: Wed Jun 22, 2016 7:05 am
by Serhii Kulibaba
Please use "page show" event instead of the "load" for that.
Do you need further assistance?
Auto refresh
Posted: Wed Jun 22, 2016 9:07 am
by rabia batool
Thank you for your response. I tried by replacing load with page show event but still its not loading for every new message in database in that conversation. It just load when page is loaded and when user click on send button.
Auto refresh
Posted: Wed Jun 22, 2016 11:42 am
by Serhii Kulibaba
The best sollution in that case is: Send push notification, right after create service executes