Auto Web Page Changer using iframe

Oh I like this. In seeking to setup a rolling web browser display display at work, I came upon this small but very clever bit of javascript, which on a timer will change the web page being viewed inside an iframe. Just edit the defaults to you preferred pages and timings and away you go:

 <!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Strict//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd”>
<html>
<head>
<meta http-equiv=”Content-Type” content=”text/html; charset=utf-8″ />
<title>Changing Pages… Please Wait</title>
<script type=”text/javascript”>
var frames = Array(‘http://www.google.com/’, 15,
‘http://www.yahoo.com/’, 15,
‘http://www.ask.com/’, 15,
‘http://www.dogpile.com/’, 15);
var i = 0, len = frames.length;
function ChangeSrc()
{
if (i >= len) { i = 0; } // start over
document.getElementById(‘frame’).src = frames[i++];
setTimeout(‘ChangeSrc()’, (frames[i++]*1000));
}
window.onload = ChangeSrc;
</script>
</head>
<body>
<iframe src=”” name=”frame” id=”frame” width=”100%” height=”100%”></iframe>
</body>
</html>

Continue reading

Simple Linux Slideshows

For running in X:

Use feh

sudo apt-get install feh

Set up a directory with photos in it, e.g. ~/photos or ~/Pictures and then run this command:

feh -zZxF -D 10 ~/photos

(-z for random, -Z for autozoom, -x for borderless windows, -F for fullscreen, -D for time on screen)

You might try using unclutter to get rid of the mouse cursor, but on some setups this doesn’t work well with feh, alternatively just move the mouse down into a corner somewhere

Continue reading

Jinamp Party Piece

Jinamp Party Piece

Ok, daughter having birthday party, kicking us out of the house for the evening. Last year, I set her up with Audacious on the htpc so that she and her guests could chose music to play, with a couple of backup options of using xbmc or a DVD full of mp3s. This year we have a new machine running as htpc, no DVD drive. Also, daughter just wants a shuffled playlist to run, with no intervention.

A few weeks ago I was mooching about on KMandla’s new wiki of CLI apps, and came across jinamp , which is a sort of background player. What it does is takes the feed of a directory or playlist, shuffles it, then sequences it to a player of its or your choice, then disappears off into the background.

Continue reading