forcing refresh to borwser
7 posts by 3 authors in: Forums > CMS Builder
Last Post: February 20, 2012 (RSS)
By rez - February 16, 2012 - edited: February 16, 2012
Once the page is loaded, I dont want to auto refresh daily or any other interval. If the screen / browser is offline, the refresh would make the page fail. Unfortunately, this would happen there and also, its not convenient to get to that computer. Also, due to bandwidth consumption, I don't want to refresh unnecessarily every hour if not needed anyway.
I would like to force a refresh somehow when I update the slideshow content without having to go to that computer and reload the page. Is this possible? Or if an auto check could be done (maybe daily) to see if the browser was connected to cmsb / online and only then update would be great.
1. a daily refresh is fine if its possible to make sure it doesnt stop the show if not connected.
2. some type of manual, remote refresh or at least that affect would be great after I update content. This is what I really want the outcome to be.
Any browser or the latest technology like html 5 or whatever is fine in this case. i can use whatever i need.
Any solution for this? thanks!
Re: [rez] forcing refresh to borwser
I’m not sure what you mean by, “If the screen / browser is offline, the refresh would make the page fail”, but here are a few articles I found. Hope they give you some ideas.
Jerry Kornbluth
http://stackoverflow.com/questions/4061111/make-field-data-change-in-real-time-without-refresh-how-on-a-website
http://www.phpsimplicity.com/tips.php?id=16
http://www.mousewhisperer.co.uk/ajax_page.html
Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php
Re: [gkornbluth] forcing refresh to borwser
By rez - February 16, 2012 - edited: February 16, 2012
Still, I will need something in my function that is set with an interval like below.
On first visit, load everything in cache and save the date and time of the last update in cmsb. in intervals:
1. check to see if server can be reached (internet connection). if not, do nothing. i dont want any errors or the screen going blank because new content check cant be reached.
2. check the date and time to the second of the last save in cmsb? if its the same as saved on load, do nothing because there isnt any new content. That way all these large photos arent loading again and eating bandwidth every interval.
3. if there is a newer save, load that content and replace the current.
Something like that. I'd even get a custom plug-in if thats the way to go.
Re: [rez] forcing refresh to borwser
there's probably an easier approach, but if you could save the updated date in a variable on your viewer when you first load the show, and then use the ideas in the previous post to only perform an update if the updatedDate on the record is later than the previous updated date, that might be an approach.
There's a bunch of information on comparing dates in another post I just answered http://www.interactivetools.com/forum/gforum.cgi?post=92253 and in my CMSB Cookbook at http://www.thecmsbcookbook.com
If you get this working, I hope you'll share the solution here on the forum.
Good luck,
Jerry Kornbluth
Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php
Re: [rez] forcing refresh to borwser
Did you ever get this sorted out?
Jerry Kornbluth
Take advantage of a free 3 month trial subscription, only for CMSB users, at: http://www.thecmsbcookbook.com/trial.php
Re: [rez] forcing refresh to borwser
By Jason - February 20, 2012
There would be a couple of different options for doing this. We would definitely need to use jQuery to attempt to connect to the server to look for differences and then update parts of the page if a difference was detected. If you are interested in this, please send in an email to consulting@interactivetools.com with a list of requirements and we can go over some options.
Hope this helps
Jason Sauchuk - Project Manager
interactivetools.com
Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/
Re: [gkornbluth] forcing refresh to borwser
By rez - February 20, 2012 - edited: February 20, 2012
thank you both.