< Distorted (stretched) audio with DVB-T & Nuvexport
archive
SPF with bethere.co.uk>
(blog entry)
Sunday 1 February 2009
Mythtv - simple remote control
The mythtv remote control interface is too heavy weight for some PDAs/smart phones, it appears to use javascript (for AJAX), and cookies. This is a simple version that uses the same API, but uses only pure HTML.
Note, you'll need to tweak your /var/www/mythweb/.htaccess file to pass through the db_* environment variables.
$keys = array(
array("id" => "escape", "name"=>"Back"),
array("id" => "enter", "name"=>"Enter"),
array("id" => "left", "name"=>"left"),
array("id" => "right", "name"=>"right"),
array("id" => "up", "name"=>"up"),
array("id" => "down", "name"=>"down"),
array("id" => "f10", "name"=>"Pause")
);
if (isset($_REQUEST['key'])) {
$key = $_REQUEST['key'];
$frontend=$Frontends['brimstone'];
$ret=$frontend->connect(3);
$ret=$frontend->send_key($key);
}
foreach ($keys as $key_obj) {
$link=$_SERVER['PHP_SELF']."?key={$key_obj['id']}";
echo "<a href=\"$link\">{$key_obj['name']}</a> <br />\n";
}