include $cfgFile;
}
-if (strtolower($fullUri) == '/setupapp/radio567/asp/browsexpa/loginxml.asp?token=0') {
- //initial login for "internet radio" and podcasts
- //lowercase tags
+if (strtolower($fullUri) == '/setupapp/radio567/asp/browsexpa/loginxml.asp?token=0'
+ || $fullUri == '/RadioNativeLogin.php'
+) {
+ //initial login for "internet radio", podcasts and "my noxon"
header('Content-type: text/html');
- readfile($dataDir . 'initial-login.xml');
- exit();
-} else if ($fullUri == '/RadioNativeLogin.php') {
- //initial login for "My noxon"
- //this one wants CamelCased tags
- header('Content-type: text/html');
- readfile($dataDir . 'login-mynoxon.xml');
+ readfile($dataDir . 'login-camelcase.xml');
exit();
} else if ($path == '/setupapp/radio567/asp/BrowseXPA/LoginXML.asp') {
//"Internet Radio"
} else if ($path == '/RadioNative.php') {
//"My Noxon"
$path = '/mynoxon/';
- $path = '/internetradio/';
} else if ($path == '/setupapp/radio567/asp/BrowseXML/FavXML.asp') {
//Internet Radio Station favorites favorited on device
sendMessage('Unsupported');
foreach ($entries as $entry) {
$urlPath = pathEncode(substr($entry, strlen($varDir)));
$ext = pathinfo($entry, PATHINFO_EXTENSION);
+
+ $titleBase = basename($entry);
+ $titleBase = preg_replace('#^[0-9]+_#', '', $titleBase);
if (is_dir($entry)) {
++$count;
- $listItems[] = getDirItem(basename($entry), $urlPath . '/');
+ $listItems[] = getDirItem($titleBase, $urlPath . '/');
} else if ($ext == 'url') {
//podcast
++$count;
- $listItems[] = getPodcastItem(basename($entry, '.url'), $urlPath);
+ $listItems[] = getPodcastItem(basename($titleBase, '.url'), $urlPath);
} else if (substr($entry, -8) == '.auto.sh') {
//automatically execute script while listing this directory
addScriptOutput($listItems, $entry);
} else if ($ext == 'txt' || $ext == 'sh') {
//plain text file
++$count;
- $listItems[] = getDirItem(basename($entry, '.' . $ext), $urlPath);
+ $listItems[] = getDirItem(basename($titleBase, '.' . $ext), $urlPath);
}
}
if (!$count) {