| |||||||||||
| |||||||||||
Changing a screen saver from a web page (PHP, Perl, OSX)
Here's a challenge. I want to change the screen saver on a mac mini, running OSX, from a browser anywhere in the world.
You may well ask why ... the screen of the mac mini is to be visible at Well House Manor where it will provide an information screen at the front door when it's not otherwise in use, and we want it to say things like "Sorry - no Vacancies" and "Welcome to the Chamber of Commerce" Task achieved! Using PHP ... and Perl ... and Web2 technology. With a smattering of OSX!Here's the control widget on our web page ... the page is in PHP and this particular widget is only displayed to staff members who are logged in - if you look at our Staff Resources Page you won't see it. And the PHP that's run when you press the update button: if ($_POST[door] == 12) { // Door Status changedThat piece of viewing software was called a controller on the Mac - which is running as a Web Server on a port enabled on our firewall, and redirected with NATS to the Mac Mini. The Perl software dodo.pl looks like this: #!/usr/bin/perlAnd there's also a standalone version here if you want to download a copy for your own use. You'll notice - typical use of PHP to front a web application, typical use of Perl as "glueware", and typical use of a Unix / Linux / OSX utility - in this case Mac's ScreenSaverEngine - to do the oddball job we needed. (written 2008-05-06 17:49:19) Associated topics are indexed under P258 - Perl - Solaris, OSX and LinuxH307 - PHP - Web2 and caching A164 - Web Application Deployment - Services and Regular Jobs
Some other Articles
Providing exceptional service - and carrying on doing so.What to do if the Home Page is missing Spring in Devizes Kiss and Book Changing a screen saver from a web page (PHP, Perl, OSX) Lua - a powerful, up and coming scripting language Looking back through some photos To provide external links, or not? A short introduction to our courses Gant charts - drawing them with a PHP script 1754 posts, page by page
Link to page ... 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36 at 50 posts per pageThis is a page archived from The Horse's Mouth at http://www.wellho.net/horse/ - the diary and writings of Graham Ellis. Every attempt was made to provide current information at the time the page was written, but things do move forward in our business - new software releases, price changes, new techniques. Please check back via our main site for current courses, prices, versions, etc - any mention of a price in "The Horse's Mouth" cannot be taken as an offer to supply at that price. Link to Ezine home page (for reading). Link to Blogging home page (to add comments). |
| ||||||||||
PH: 0800 043 8225 or 01225 708225 • FAX: 0845 8382 405 or 01225 707126 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho | |||||||||||