-return json as data type for schedule action

This commit is contained in:
Martin Konecny 2012-09-10 16:54:42 -04:00
parent fba0e18620
commit 5292137430
2 changed files with 1 additions and 1 deletions

View File

@ -337,6 +337,7 @@ class ApiController extends Zend_Controller_Action
$this->_helper->viewRenderer->setNoRender(true); $this->_helper->viewRenderer->setNoRender(true);
$data = Application_Model_Schedule::getSchedule(); $data = Application_Model_Schedule::getSchedule();
header("Content-Type: application/json");
echo json_encode($data, JSON_FORCE_OBJECT); echo json_encode($data, JSON_FORCE_OBJECT);
} }

View File

@ -262,7 +262,6 @@ class Application_Model_Webstream implements Application_Model_LibraryEditable
private static function getPlsUrl($url) private static function getPlsUrl($url)
{ {
$content = self::getUrlData($url); $content = self::getUrlData($url);
$ini = parse_ini_string($content, true); $ini = parse_ini_string($content, true);
if ($ini !== false && isset($ini["playlist"]) && isset($ini["playlist"]["File1"])) { if ($ini !== false && isset($ini["playlist"]) && isset($ini["playlist"]["File1"])) {