Refresh Websites Automatically

Many websites update their content periodically using JavaScript, and in the past Twitter widgets used this mechanism, too. The website you used in the preceding section uses a different approach. It updates its content using the <meta> tag in the head section of the HTML page.

 
<meta​ http-equiv=​"refresh"​ content=​"120"​​>​​</meta>

This element reloads the page every 120 seconds. It’s an easy solution, but it works only when you’re allowed to change the page and have access to the server hosting it. So, the best solution would be if you could tell your browser to reload the current page at a certain interval. Most browsers have such a function, and usually it’s called kiosk mode. Midori has a kiosk mode, ...

Get Raspberry Pi, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.