id); return $url; } // get_url /** * get_file * This returns the Filename for the passed object, not * always possible */ public function get_file($object) { } // get_file /** * parse_url * This takes an Ampache URL and then returns the 'primary' part of it * So that it's easier for localplay modules to return valid song information */ public function parse_url($url) { // Define possible 'primary' keys $primary_array = array('oid','demo_id','random'); $data = array(); $variables = parse_url($url,PHP_URL_QUERY); parse_str($variables,$data); foreach ($primary_array as $pkey) { if ($data[$pkey]) { $data['primary_key'] = $pkey; return $data; } } // end foreach return $data; } // parse_url } // end localplay_controller interface