chore(legacy): use Config::getBasePath helper
Replace Application_Common_OsPath::getBaseDir with Config::getBasePath.
This commit is contained in:
parent
712ecd70b4
commit
72960593c7
|
@ -50,7 +50,7 @@ class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
|
|||
{
|
||||
$front = Zend_Controller_Front::getInstance();
|
||||
$router = $front->getRouter();
|
||||
$front->setBaseUrl(Application_Common_OsPath::getBaseDir());
|
||||
$front->setBaseUrl(Config::getBasePath());
|
||||
|
||||
$router->addRoute(
|
||||
'password-change',
|
||||
|
|
|
@ -73,22 +73,6 @@ class Application_Common_OsPath
|
|||
return implode(DIRECTORY_SEPARATOR, $paths);
|
||||
}
|
||||
|
||||
public static function getBaseDir()
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = $CC_CONFIG['baseDir'];
|
||||
|
||||
if ($baseUrl[0] != '/') {
|
||||
$baseUrl = '/' . $baseUrl;
|
||||
}
|
||||
|
||||
if ($baseUrl[strlen($baseUrl) - 1] != '/') {
|
||||
$baseUrl = $baseUrl . '/';
|
||||
}
|
||||
|
||||
return $baseUrl;
|
||||
}
|
||||
|
||||
public static function formatDirectoryWithDirectorySeparators($dir)
|
||||
{
|
||||
if ($dir[0] != '/') {
|
||||
|
|
|
@ -1516,7 +1516,7 @@ class ApiController extends Zend_Controller_Action
|
|||
*/
|
||||
public function showTracksAction()
|
||||
{
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$prefTimezone = Application_Model_Preference::GetTimezone();
|
||||
|
||||
$instanceId = $this->_getParam('instance_id');
|
||||
|
|
|
@ -24,7 +24,7 @@ class AudiopreviewController extends Zend_Controller_Action
|
|||
$audioFileID = $this->_getParam('audioFileID');
|
||||
$type = $this->_getParam('type');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$this->view->headScript()->appendFile(
|
||||
$baseUrl . 'js/airtime/audiopreview/preview_jplayer.js?' . $CC_CONFIG['airtime_version'],
|
||||
|
@ -81,7 +81,7 @@ class AudiopreviewController extends Zend_Controller_Action
|
|||
$playlistIndex = $this->_getParam('playlistIndex');
|
||||
$playlistID = $this->_getParam('playlistID');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/airtime/audiopreview/preview_jplayer.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/jplayer/jplayer.playlist.min.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
|
@ -107,7 +107,7 @@ class AudiopreviewController extends Zend_Controller_Action
|
|||
$blockIndex = $this->_getParam('blockIndex');
|
||||
$blockId = $this->_getParam('blockId');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/airtime/audiopreview/preview_jplayer.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/jplayer/jplayer.playlist.min.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
|
@ -182,7 +182,7 @@ class AudiopreviewController extends Zend_Controller_Action
|
|||
|
||||
private function createElementMap($track)
|
||||
{
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$elementMap = [
|
||||
'element_title' => isset($track['track_title']) ? $track['track_title'] : '',
|
||||
|
@ -229,7 +229,7 @@ class AudiopreviewController extends Zend_Controller_Action
|
|||
$showID = $this->_getParam('showID');
|
||||
$showIndex = $this->_getParam('showIndex');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/airtime/audiopreview/preview_jplayer.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/jplayer/jplayer.playlist.min.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
|
@ -254,7 +254,7 @@ class AudiopreviewController extends Zend_Controller_Action
|
|||
*/
|
||||
public function getShowAction()
|
||||
{
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
// disable the view and the layout
|
||||
$this->view->layout()->disableLayout();
|
||||
$this->_helper->viewRenderer->setNoRender(true);
|
||||
|
|
|
@ -95,7 +95,7 @@ class DashboardController extends Zend_Controller_Action
|
|||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$this->view->headLink()->appendStylesheet($baseUrl . 'js/jplayer/skin/jplayer.blue.monday.css?' . $CC_CONFIG['airtime_version']);
|
||||
$this->_helper->layout->setLayout('livestream');
|
||||
|
@ -122,7 +122,7 @@ class DashboardController extends Zend_Controller_Action
|
|||
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$headScript = $this->view->headScript();
|
||||
AirtimeTableView::injectTableJavaScriptDependencies($headScript, $baseUrl, $CC_CONFIG['airtime_version']);
|
||||
|
|
|
@ -11,7 +11,7 @@ class EmbeddableWidgetsController extends Zend_Controller_Action
|
|||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Widgets');
|
||||
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$this->view->headLink()->appendStylesheet($baseUrl . 'css/player-form.css?' . $CC_CONFIG['airtime_version']);
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/airtime/player/player.js?' . $CC_CONFIG['airtime_version']);
|
||||
|
||||
|
@ -54,7 +54,7 @@ class EmbeddableWidgetsController extends Zend_Controller_Action
|
|||
}
|
||||
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$facebookAppId = $CC_CONFIG['facebook-app-id'];
|
||||
$this->view->headScript()->appendScript('var FACEBOOK_APP_ID = ' . json_encode($facebookAppId) . ';');
|
||||
|
|
|
@ -13,7 +13,7 @@ class ErrorController extends Zend_Controller_Action
|
|||
try {
|
||||
$service_user = new Application_Service_UserService();
|
||||
$service_user->getCurrentUser();
|
||||
$this->view->helpUrl = Application_Common_OsPath::getBaseDir() . 'dashboard/help';
|
||||
$this->view->helpUrl = Config::getBasePath() . 'dashboard/help';
|
||||
} catch (Exception $e) {
|
||||
$this->view->helpUrl = HELP_URL;
|
||||
}
|
||||
|
|
|
@ -9,7 +9,7 @@ class IndexController extends Zend_Controller_Action
|
|||
public function indexAction()
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$this->view->headTitle(Application_Model_Preference::GetHeadTitle());
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/libs/jquery-1.8.3.min.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
|
||||
|
|
|
@ -76,7 +76,7 @@ class LibraryController extends Zend_Controller_Action
|
|||
|
||||
public function contextMenuAction()
|
||||
{
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$id = $this->_getParam('id');
|
||||
$type = $this->_getParam('type');
|
||||
// playlist||timeline
|
||||
|
|
|
@ -15,7 +15,7 @@ class ListenerstatController extends Zend_Controller_Action
|
|||
$CC_CONFIG = Config::getConfig();
|
||||
|
||||
$request = $this->getRequest();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Analytics');
|
||||
|
||||
|
@ -61,7 +61,7 @@ class ListenerstatController extends Zend_Controller_Action
|
|||
$CC_CONFIG = Config::getConfig();
|
||||
|
||||
$request = $this->getRequest();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$headScript = $this->view->headScript();
|
||||
AirtimeTableView::injectTableJavaScriptDependencies($headScript, $baseUrl, $CC_CONFIG['airtime_version']);
|
||||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Analytics');
|
||||
|
|
|
@ -5,7 +5,7 @@ class LoginController extends Zend_Controller_Action
|
|||
public function init()
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$this->view->headLink(['rel' => 'icon', 'href' => $baseUrl . 'favicon.ico?' . $CC_CONFIG['airtime_version'], 'type' => 'image/x-icon'], 'PREPEND')
|
||||
->appendStylesheet($baseUrl . 'css/bootstrap.css?' . $CC_CONFIG['airtime_version'])
|
||||
|
@ -43,7 +43,7 @@ class LoginController extends Zend_Controller_Action
|
|||
|
||||
$this->view->error = false;
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$form = new Application_Form_Login();
|
||||
|
||||
|
@ -113,7 +113,7 @@ class LoginController extends Zend_Controller_Action
|
|||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/airtime/login/password-restore.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
|
||||
|
|
|
@ -22,7 +22,7 @@ class PlayouthistoryController extends Zend_Controller_Action
|
|||
public function indexAction()
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Analytics');
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ class PlayouthistorytemplateController extends Zend_Controller_Action
|
|||
public function indexAction()
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Analytics');
|
||||
|
||||
|
@ -32,7 +32,7 @@ class PlayouthistorytemplateController extends Zend_Controller_Action
|
|||
public function configureTemplateAction()
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Analytics');
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ class PluploadController extends Zend_Controller_Action
|
|||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$locale = Application_Model_Preference::GetLocale();
|
||||
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/datatables/js/jquery.dataTables.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
|
|
|
@ -5,7 +5,7 @@ class PodcastController extends Zend_Controller_Action
|
|||
public function init()
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$headScript = $this->view->headScript();
|
||||
AirtimeTableView::injectTableJavaScriptDependencies($headScript, $baseUrl, $CC_CONFIG['airtime_version']);
|
||||
|
|
|
@ -25,7 +25,7 @@ class PreferenceController extends Zend_Controller_Action
|
|||
|
||||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Settings');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/airtime/preferences/preferences.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
$this->view->statusMsg = '';
|
||||
|
@ -137,7 +137,7 @@ class PreferenceController extends Zend_Controller_Action
|
|||
|
||||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Settings');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/airtime/preferences/streamsetting.js?' . $CC_CONFIG['airtime_version'], 'text/javascript');
|
||||
|
||||
|
|
|
@ -44,7 +44,7 @@ class ScheduleController extends Zend_Controller_Action
|
|||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
// Embed the schedule in our page response so we don't have to make an AJAX request to get this data after the page load.
|
||||
$scheduleController = new ScheduleController($this->getRequest(), $this->getResponse());
|
||||
|
|
|
@ -18,7 +18,7 @@ class ShowbuilderController extends Zend_Controller_Action
|
|||
public function indexAction()
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$userType = Application_Model_User::GetCurrentUser()->getType();
|
||||
|
||||
// $this->_helper->layout->setLayout("showbuilder");
|
||||
|
@ -100,7 +100,7 @@ class ShowbuilderController extends Zend_Controller_Action
|
|||
public function checkAndShowSetupPopup($request)
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$setupComplete = Application_Model_Preference::getLangTimezoneSetupComplete();
|
||||
$previousPage = strtolower($request->getHeader('Referer'));
|
||||
$userService = new Application_Service_UserService();
|
||||
|
@ -119,7 +119,7 @@ class ShowbuilderController extends Zend_Controller_Action
|
|||
|
||||
public function contextMenuAction()
|
||||
{
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$id = $this->_getParam('id');
|
||||
$now = floatval(microtime(true));
|
||||
|
|
|
@ -7,7 +7,7 @@ class SystemstatusController extends Zend_Controller_Action
|
|||
public function init()
|
||||
{
|
||||
$config = Config::getConfig();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$this->view->headScript()->appendFile($baseUrl . 'js/airtime/status/status.js?' . $config['airtime_version'], 'text/javascript');
|
||||
$this->version = $config['airtime_version'];
|
||||
}
|
||||
|
|
|
@ -22,7 +22,7 @@ class TracktypeController extends Zend_Controller_Action
|
|||
|
||||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Settings');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$js_files = [
|
||||
'js/datatables/js/jquery.dataTables.js?',
|
||||
|
|
|
@ -24,7 +24,7 @@ class UserController extends Zend_Controller_Action
|
|||
|
||||
Zend_Layout::getMvcInstance()->assign('parent_page', 'Settings');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$js_files = [
|
||||
'js/datatables/js/jquery.dataTables.js?',
|
||||
|
|
|
@ -73,7 +73,7 @@ class PageLayoutInitPlugin extends Zend_Controller_Plugin_Abstract
|
|||
}
|
||||
|
||||
$view = $this->_bootstrap->getResource('view');
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$view->headScript()->appendScript("var baseUrl = '{$baseUrl}';");
|
||||
$this->_initTranslationGlobals($view);
|
||||
|
@ -156,7 +156,7 @@ class PageLayoutInitPlugin extends Zend_Controller_Plugin_Abstract
|
|||
|
||||
$view = $this->_bootstrap->getResource('view');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$view->headLink(['rel' => 'icon', 'href' => $baseUrl . 'favicon.ico?' . $CC_CONFIG['airtime_version'], 'type' => 'image/x-icon'], 'PREPEND')
|
||||
->appendStylesheet($baseUrl . 'css/bootstrap.css?' . $CC_CONFIG['airtime_version'])
|
||||
|
@ -178,7 +178,7 @@ class PageLayoutInitPlugin extends Zend_Controller_Plugin_Abstract
|
|||
|
||||
$view = $this->_bootstrap->getResource('view');
|
||||
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$view->headScript()->appendFile($baseUrl . 'js/libs/jquery-1.8.3.min.js?' . $CC_CONFIG['airtime_version'], 'text/javascript')
|
||||
->appendFile($baseUrl . 'js/libs/jquery-ui-1.8.24.min.js?' . $CC_CONFIG['airtime_version'], 'text/javascript')
|
||||
|
|
|
@ -8,7 +8,6 @@ class Application_Form_EditAudioMD extends Zend_Form
|
|||
|
||||
public function startForm($p_id)
|
||||
{
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
// Set the method for the display form to POST
|
||||
$this->setMethod('post');
|
||||
|
||||
|
|
|
@ -4,8 +4,6 @@ class Application_Form_Preferences extends Zend_Form
|
|||
{
|
||||
public function init()
|
||||
{
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
|
||||
$this->setDecorators([
|
||||
['ViewScript', ['viewScript' => 'form/preferences.phtml']],
|
||||
]);
|
||||
|
|
|
@ -1,125 +1,133 @@
|
|||
<?php echo $this->doctype() ?>
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<?php echo $this->headTitle() ?>
|
||||
<?php echo $this->headLink() ?>
|
||||
<?php echo $this->headScript() ?>
|
||||
<?php $baseUrl = Application_Common_OsPath::getBaseDir(); ?>
|
||||
<?php echo $this->headLink() ?>
|
||||
<?php echo $this->headScript() ?>
|
||||
<?php $baseUrl = Config::getBasePath(); ?>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="Panel" class="sticky">
|
||||
<?php
|
||||
/*
|
||||
<?php
|
||||
/*
|
||||
NOTE: Temporarily disabled version notification to avoid confusion,
|
||||
Users can check current version in Settings > Status.
|
||||
*/
|
||||
//echo $this->versionNotify();
|
||||
$sss = $this->SourceSwitchStatus();
|
||||
$scs = $this->SourceConnectionStatus();
|
||||
?>
|
||||
<?php echo $this->partial('partialviews/header.phtml', array("live_dj_switch"=>$sss['live_dj'], "live_dj_connection"=>$scs['live_dj'], "master_dj_switch"=>$sss['master_dj'], "master_dj_connection"=>$scs['master_dj'],
|
||||
"scheduled_play_switch"=>$sss['scheduled_play'])) ?>
|
||||
<?php $partial = array('menu.phtml', 'default');
|
||||
$this->navigation()->menu()->setPartial($partial); ?>
|
||||
//echo $this->versionNotify();
|
||||
$sss = $this->SourceSwitchStatus();
|
||||
$scs = $this->SourceConnectionStatus();
|
||||
?>
|
||||
<?php echo $this->partial('partialviews/header.phtml', array(
|
||||
"live_dj_switch" => $sss['live_dj'], "live_dj_connection" => $scs['live_dj'], "master_dj_switch" => $sss['master_dj'], "master_dj_connection" => $scs['master_dj'],
|
||||
"scheduled_play_switch" => $sss['scheduled_play']
|
||||
)) ?>
|
||||
<?php $partial = array('menu.phtml', 'default');
|
||||
$this->navigation()->menu()->setPartial($partial); ?>
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
var schedulePreLoaded = <?php
|
||||
//Awful hack to speed up loading - Embed the schedule in the response so that the dashboard
|
||||
//doesn't have to make a separate AJAX request to get this data.
|
||||
ScheduleController::printCurrentPlaylistForEmbedding();
|
||||
?>;
|
||||
//The DOM elements that these calls depend on exist by this point:
|
||||
parseItems(schedulePreLoaded.entries);
|
||||
parseSourceStatus(schedulePreLoaded.source_status);
|
||||
parseSwitchStatus(schedulePreLoaded.switch_status);
|
||||
|
||||
</script>
|
||||
</div>
|
||||
|
||||
<div id="media_type_nav"> <!-- class="content-pane" -->
|
||||
<div class="btn-group">
|
||||
<ul class="dropdown-menu">
|
||||
<li id="new-playlist">
|
||||
<a href="#"><?php echo _("Playlist") ?></a>
|
||||
</li>
|
||||
<li id="new-smart-block">
|
||||
<a href="#"><?php echo _("Smart Block") ?></a>
|
||||
</li>
|
||||
<li id="new-webstream">
|
||||
<a href="#"><?php echo _("Webstream") ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
<a href="<?php echo Application_Common_OsPath::getBaseDir() . 'plupload' ?>">
|
||||
<button id="add_media_btn" class="btn btn-small dashboard-btn btn-new">
|
||||
<span><?php echo _("Upload") ?></span>
|
||||
</button>
|
||||
</a>
|
||||
<script type="text/javascript">
|
||||
var schedulePreLoaded = <?php
|
||||
//Awful hack to speed up loading - Embed the schedule in the response so that the dashboard
|
||||
//doesn't have to make a separate AJAX request to get this data.
|
||||
ScheduleController::printCurrentPlaylistForEmbedding();
|
||||
?>;
|
||||
//The DOM elements that these calls depend on exist by this point:
|
||||
parseItems(schedulePreLoaded.entries);
|
||||
parseSourceStatus(schedulePreLoaded.source_status);
|
||||
parseSwitchStatus(schedulePreLoaded.switch_status);
|
||||
</script>
|
||||
</div>
|
||||
|
||||
<div class="media_type_selector top-link" data-selection-id="<?php echo MediaType::getDefault(); ?>">
|
||||
<a href="<?php echo Application_Common_OsPath::getBaseDir() . 'showbuilder#' ?>">
|
||||
<i class='icon-home icon-white'></i>
|
||||
<?php echo _("Dashboard") ?>
|
||||
</a>
|
||||
</div>
|
||||
<?php $subnavPrefix = "/showbuilder"; require_once APPLICATION_PATH . "/views/scripts/partialviews/dashboard-sub-nav.php"; ?>
|
||||
<div class="media_type_selector dashboard_sub_nav" data-selection-id="<?php echo MediaType::PODCAST ?>">
|
||||
<a href="<?php echo $subnavPrefix; ?>#podcasts">
|
||||
<span class="selector-name"><i class='icon-headphones icon-white'></i><?php echo _("Podcasts") ?></span>
|
||||
</a>
|
||||
</div>
|
||||
<div id="media_type_nav">
|
||||
<!-- class="content-pane" -->
|
||||
<div class="btn-group">
|
||||
<ul class="dropdown-menu">
|
||||
<li id="new-playlist">
|
||||
<a href="#"><?php echo _("Playlist") ?></a>
|
||||
</li>
|
||||
<li id="new-smart-block">
|
||||
<a href="#"><?php echo _("Smart Block") ?></a>
|
||||
</li>
|
||||
<li id="new-webstream">
|
||||
<a href="#"><?php echo _("Webstream") ?></a>
|
||||
</li>
|
||||
</ul>
|
||||
<a href="<?php echo Config::getBasePath() . 'plupload' ?>">
|
||||
<button id="add_media_btn" class="btn btn-small dashboard-btn btn-new">
|
||||
<span><?php echo _("Upload") ?></span>
|
||||
</button>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<hr style="margin-left: 5px; margin-right: 5px">
|
||||
<div id="nav">
|
||||
<?php echo $this->navigation()->menu(); ?>
|
||||
</div>
|
||||
<div class="media_type_selector top-link" data-selection-id="<?php echo MediaType::getDefault(); ?>">
|
||||
<a href="<?php echo Config::getBasePath() . 'showbuilder#' ?>">
|
||||
<i class='icon-home icon-white'></i>
|
||||
<?php echo _("Dashboard") ?>
|
||||
</a>
|
||||
</div>
|
||||
<?php $subnavPrefix = "/showbuilder";
|
||||
require_once APPLICATION_PATH . "/views/scripts/partialviews/dashboard-sub-nav.php"; ?>
|
||||
<div class="media_type_selector dashboard_sub_nav" data-selection-id="<?php echo MediaType::PODCAST ?>">
|
||||
<a href="<?php echo $subnavPrefix; ?>#podcasts">
|
||||
<span class="selector-name"><i class='icon-headphones icon-white'></i><?php echo _("Podcasts") ?></span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
<?php
|
||||
$partitions = Application_Model_Systemstatus::GetDiskInfo();
|
||||
$status = new StdClass;
|
||||
$disk = $partitions[0];
|
||||
$used = $disk->totalSpace-$disk->totalFreeSpace;
|
||||
$total = $disk->totalSpace;
|
||||
echo "var remainingDiskSpace = ".$disk->totalFreeSpace.";";
|
||||
?>
|
||||
</script>
|
||||
<div id="disk_usage">
|
||||
<!--<div style="padding-bottom: 2px;">Disk Usage</div>-->
|
||||
<div class="disk_usage_progress_bar"></div>
|
||||
<div class="disk_usage_percent_in_use"><?php echo sprintf("%01.1fGB of %01.1fGB", $used/pow(2, 30), $total/pow(2, 30)); ?></div>
|
||||
<div class="disk_usage_used" style="width:<?php echo sprintf("%01.1f%%", min(100, $used/$total*100)) ?>;"></div>
|
||||
<hr style="margin-left: 5px; margin-right: 5px">
|
||||
<div id="nav">
|
||||
<?php echo $this->navigation()->menu(); ?>
|
||||
</div>
|
||||
|
||||
<!--<div style="margin-top: 15px; font-size: 12px;">
|
||||
<?php //echo sprintf("%01.1fGB of %01.1fGB", $used/pow(2, 30), $total/pow(2, 30)); ?>
|
||||
<script>
|
||||
<?php
|
||||
$partitions = Application_Model_Systemstatus::GetDiskInfo();
|
||||
$status = new StdClass;
|
||||
$disk = $partitions[0];
|
||||
$used = $disk->totalSpace - $disk->totalFreeSpace;
|
||||
$total = $disk->totalSpace;
|
||||
echo "var remainingDiskSpace = " . $disk->totalFreeSpace . ";";
|
||||
?>
|
||||
</script>
|
||||
<div id="disk_usage">
|
||||
<!--<div style="padding-bottom: 2px;">Disk Usage</div>-->
|
||||
<div class="disk_usage_progress_bar"></div>
|
||||
<div class="disk_usage_percent_in_use"><?php echo sprintf("%01.1fGB of %01.1fGB", $used / pow(2, 30), $total / pow(2, 30)); ?></div>
|
||||
<div class="disk_usage_used" style="width:<?php echo sprintf("%01.1f%%", min(100, $used / $total * 100)) ?>;"></div>
|
||||
|
||||
<!--<div style="margin-top: 15px; font-size: 12px;">
|
||||
<?php //echo sprintf("%01.1fGB of %01.1fGB", $used/pow(2, 30), $total/pow(2, 30));
|
||||
?>
|
||||
</div>-->
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<?php $hint = Application_Common_UsabilityHints::getUsabilityHint(); ?>
|
||||
<div class="usability_hint <?php if ($hint == "") {
|
||||
echo "hidden";
|
||||
} ?>"><?php echo $hint; ?></div>
|
||||
|
||||
<?php $hint = Application_Common_UsabilityHints::getUsabilityHint(); ?>
|
||||
<div class="usability_hint <?php if ($hint == "") { echo "hidden"; } ?>"><?php echo $hint; ?></div>
|
||||
|
||||
<div class="wrapper <?php if (isset($this->layout()->parent_page)) echo "wrapper_panel";?>" id="content">
|
||||
<?php echo $this->layout()->content ?>
|
||||
</div>
|
||||
<?php if (isset($this->layout()->parent_page)) { ?>
|
||||
<div id="sub-menu">
|
||||
<h3><?php //parent_page is passed in from controller
|
||||
echo _($this->layout()->parent_page); ?></h3>
|
||||
<hr>
|
||||
<?php
|
||||
$page = $this->navigation()->findOneBy('title', $this->layout()->parent_page);
|
||||
echo $this->navigation()->menu()->render($page);
|
||||
?>
|
||||
<div class="wrapper <?php if (isset($this->layout()->parent_page)) echo "wrapper_panel"; ?>" id="content">
|
||||
<?php echo $this->layout()->content ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
<?php if (isset($this->layout()->parent_page)) { ?>
|
||||
<div id="sub-menu">
|
||||
<h3><?php //parent_page is passed in from controller
|
||||
echo _($this->layout()->parent_page); ?></h3>
|
||||
<hr>
|
||||
<?php
|
||||
$page = $this->navigation()->findOneBy('title', $this->layout()->parent_page);
|
||||
echo $this->navigation()->menu()->render($page);
|
||||
?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<script id="tmpl-pl-cues" type="text/template">
|
||||
<div class="waveform-cues">
|
||||
<script id="tmpl-pl-cues" type="text/template">
|
||||
<div class="waveform-cues">
|
||||
<div class="playlist-time-scale"></div>
|
||||
<div class="playlist-tracks"></div>
|
||||
<div class="playlist-controls">
|
||||
|
@ -144,8 +152,8 @@
|
|||
</div>
|
||||
</script>
|
||||
|
||||
<script id="tmpl-pl-fades" type="text/template">
|
||||
<div class="waveform-fades">
|
||||
<script id="tmpl-pl-fades" type="text/template">
|
||||
<div class="waveform-fades">
|
||||
<div class="playlist-time-scale"></div>
|
||||
<div class="playlist-tracks"></div>
|
||||
<div class="playlist-controls left-floated">
|
||||
|
@ -161,11 +169,11 @@
|
|||
</div>
|
||||
</script>
|
||||
|
||||
<?php
|
||||
<?php
|
||||
// Show users the What's New dialog if they haven't seen it yet
|
||||
// TODO: If you're updating this, be sure to update defaultdata! (Suboptimal, is there a better way?)
|
||||
if (!Application_Model_Preference::getWhatsNewDialogViewed()) {
|
||||
?>
|
||||
?>
|
||||
<div id="whatsnew">
|
||||
<div>
|
||||
<div id="whatsnew_video">
|
||||
|
@ -197,13 +205,14 @@
|
|||
});
|
||||
});
|
||||
</script>
|
||||
<?php
|
||||
<?php
|
||||
Application_Model_Preference::setWhatsNewDialogViewed(true);
|
||||
}
|
||||
?>
|
||||
?>
|
||||
|
||||
<div id="fb-root"></div>
|
||||
<div id="fb-root"></div>
|
||||
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
||||
|
|
|
@ -140,11 +140,9 @@ class Application_Model_Auth
|
|||
*/
|
||||
public static function pinSessionToClient($auth)
|
||||
{
|
||||
$CC_CONFIG = Config::getConfig();
|
||||
|
||||
$serverName = isset($_SERVER['SERVER_NAME']) ? $_SERVER['SERVER_NAME'] : '';
|
||||
$remoteAddr = isset($_SERVER['REMOTE_ADDR']) ? $_SERVER['REMOTE_ADDR'] : '';
|
||||
$sessionIdentifier = 'Airtime' . '-' . $serverName . '-' . $remoteAddr . '-' . Application_Model_Preference::GetClientId() . '-' . $CC_CONFIG['baseDir'];
|
||||
$sessionIdentifier = 'Airtime' . '-' . $serverName . '-' . $remoteAddr . '-' . Application_Model_Preference::GetClientId() . '-' . Config::getBasePath();
|
||||
$auth->setStorage(new Zend_Auth_Storage_Session($sessionIdentifier));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -682,7 +682,7 @@ SQL;
|
|||
|
||||
public static function searchLibraryFiles($datatables)
|
||||
{
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
|
||||
$con = Propel::getConnection(CcFilesPeer::DATABASE_NAME);
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ class Application_Service_CalendarService
|
|||
{
|
||||
$menu = [];
|
||||
$now = time();
|
||||
$baseUrl = Application_Common_OsPath::getBaseDir();
|
||||
$baseUrl = Config::getBasePath();
|
||||
$isAdminOrPM = $this->currentUser->isAdminOrPM();
|
||||
$isHostOfShow = $this->currentUser->isHostOfShow($this->ccShow->getDbId());
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<div id="weekly-schedule-widget" class="prefpanel ui-widget simple-formblock clearfix padded-strong ">
|
||||
|
||||
<?php $baseUrl = Application_Common_OsPath::getBaseDir(); ?>
|
||||
<?php $baseUrl = Config::getBasePath(); ?>
|
||||
|
||||
<h2 style="text-align:center"><?php echo _("Facebook Radio Player") ?></h2>
|
||||
<div style="clear:both"></div>
|
||||
|
@ -27,10 +27,10 @@
|
|||
<h3 style="padding-left: 0px"><?php echo _("Tips:") ?></h3>
|
||||
<p>
|
||||
<?php echo _("To make the tab more visible on your Facebook page, click 'More', and 'Manage Tabs':") ?><br><br>
|
||||
<img src="<?php echo($baseUrl) . "images/doc/facebook_widget1.png"?>"><br><br>
|
||||
<img src="<?php echo ($baseUrl) . "images/doc/facebook_widget1.png" ?>"><br><br>
|
||||
|
||||
<?php echo _("Then, drag the Radio Player item higher in the list, and click Save. It will now appear as one of the default tabs instead of being buried under 'More':") ?><br><br>
|
||||
<img src="<?php echo($baseUrl) . "images/doc/facebook_widget2.png"?>">
|
||||
<img src="<?php echo ($baseUrl) . "images/doc/facebook_widget2.png" ?>">
|
||||
|
||||
</p>
|
||||
</div>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<div id="player-widget" class="ui-widget prefpanel simple-formblock embed-player-form clearfix padded-strong ">
|
||||
|
||||
<?php $baseUrl = Application_Common_OsPath::getBaseDir(); ?>
|
||||
<?php $baseUrl = Config::getBasePath(); ?>
|
||||
|
||||
<form method="post" id="player_form" enctype="multipart/form-data">
|
||||
<h2 style="text-align:center"><?php echo _("Player") ?></h2>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<div id="weekly-schedule-widget" class="prefpanel ui-widget simple-formblock clearfix padded-strong ">
|
||||
|
||||
<?php $baseUrl = Application_Common_OsPath::getBaseDir(); ?>
|
||||
<?php $baseUrl = Config::getBasePath(); ?>
|
||||
|
||||
<h2 style="text-align:center"><?php echo _("Weekly Schedule") ?></h2>
|
||||
<div style="clear:both"></div>
|
||||
|
@ -13,15 +13,16 @@
|
|||
<div id="weekly-schedule-widget-preview" <?php if (isset($this->weekly_schedule_error_msg)) echo "style=display:none"; ?>>
|
||||
<!-- <label><?php echo _("Preview:") ?></label> -->
|
||||
<div class="schedule_iframe_wrapper">
|
||||
<iframe id="schedule_iframe" height="400px" width="550px" scrolling="no" frameborder="0" src="<?php echo Application_Common_HTTPHelper::getStationUrl()."embed/weekly-program"?>"></iframe>
|
||||
<iframe id="schedule_iframe" height="400px" width="550px" scrolling="no" frameborder="0" src="<?php echo Application_Common_HTTPHelper::getStationUrl() . "embed/weekly-program" ?>"></iframe>
|
||||
</div>
|
||||
|
||||
<div style="clear:both"></div>
|
||||
<label><?php echo _("Embeddable code:") ?><br><br></label>
|
||||
<textarea style="width:98%" rows="3" readonly="readonly"><iframe height="400px" width="550px" scrolling="no" frameborder="0" src="<?php echo Application_Common_HTTPHelper::getStationUrl()."embed/weekly-program"?>"></iframe>
|
||||
<textarea style="width:98%" rows="3" readonly="readonly"><iframe height="400px" width="550px" scrolling="no" frameborder="0" src="<?php echo Application_Common_HTTPHelper::getStationUrl() . "embed/weekly-program" ?>"></iframe>
|
||||
</textarea>
|
||||
<div><p>
|
||||
<?php echo _("Copy this code and paste it into your website's HTML to embed the weekly schedule in your site. Adjust the height and width attributes to your desired size.") ?>
|
||||
<div>
|
||||
<p>
|
||||
<?php echo _("Copy this code and paste it into your website's HTML to embed the weekly schedule in your site. Adjust the height and width attributes to your desired size.") ?>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -1,15 +1,15 @@
|
|||
<?php $baseUrl = Application_Common_OsPath::getBaseDir(); ?>
|
||||
<?php $baseUrl = Config::getBasePath(); ?>
|
||||
<div id="import_status" class="library_import" style="display:none">
|
||||
<?php echo _("File import in progress..."); ?>
|
||||
<img src=<?php echo $baseUrl . "css/images/file_import_loader.gif"?>></img>
|
||||
<img src=<?php echo $baseUrl . "css/images/file_import_loader.gif" ?>></img>
|
||||
</div>
|
||||
|
||||
<fieldset class="toggle closed" id="filter_options">
|
||||
<legend style="cursor: pointer;">
|
||||
<span class="ui-icon ui-icon-triangle-2-n-s"></span>
|
||||
<?php echo _("Advanced Search Options") ?>
|
||||
</legend>
|
||||
<div id="advanced_search" class="advanced_search form-horizontal"></div>
|
||||
<legend style="cursor: pointer;">
|
||||
<span class="ui-icon ui-icon-triangle-2-n-s"></span>
|
||||
<?php echo _("Advanced Search Options") ?>
|
||||
</legend>
|
||||
<div id="advanced_search" class="advanced_search form-horizontal"></div>
|
||||
</fieldset>
|
||||
|
||||
<table id="library_display" cellpadding="0" cellspacing="0" class="datatable">
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<div class="ui-widget prefpanel simple-formblock clearfix padded-strong preferences">
|
||||
<h2 id="preferences_header"><?php echo _("General") ?></h2>
|
||||
<?php $baseUrl = Application_Common_OsPath::getBaseDir(); ?>
|
||||
<?php $baseUrl = Config::getBasePath(); ?>
|
||||
<form method="post" id="pref_form" enctype="multipart/form-data">
|
||||
|
||||
<?php echo $this->form->getElement('submit')->render() ?>
|
||||
|
@ -10,6 +10,6 @@
|
|||
echo $this->statusMsg;
|
||||
echo $this->form;
|
||||
?>
|
||||
<br/>
|
||||
<br />
|
||||
</form>
|
||||
</div>
|
||||
|
|
|
@ -1,121 +1,123 @@
|
|||
<div class="ui-widget prefpanel simple-formblock clearfix padded-strong stream-config">
|
||||
<h2 style="float:left"><?php echo _("Stream Settings") ?></h2>
|
||||
<?php $baseUrl = Application_Common_OsPath::getBaseDir(); ?>
|
||||
<?php $baseUrl = Config::getBasePath(); ?>
|
||||
<form method="post" id="stream_form" enctype="application/x-www-form-urlencoded">
|
||||
<button name="stream_save" id="stream_save_top" type="button" class="btn right-floated"><?php echo _("Save") ?></button>
|
||||
<?php echo $this->form->getElement('csrf') ?>
|
||||
<div style="clear:both"></div>
|
||||
<?php echo $this->statusMsg;?>
|
||||
<div style="float: left; margin-right: 10px; width: 50%; overflow: auto;">
|
||||
<button name="stream_save" id="stream_save_top" type="button" class="btn right-floated"><?php echo _("Save") ?></button>
|
||||
<?php echo $this->form->getElement('csrf') ?>
|
||||
<div style="clear:both"></div>
|
||||
<?php echo $this->statusMsg; ?>
|
||||
<div style="float: left; margin-right: 10px; width: 50%; overflow: auto;">
|
||||
|
||||
<h3><?php echo _("Global") ?></h3>
|
||||
<fieldset class="padded stream-setting-global">
|
||||
<dl class="zend_form">
|
||||
<?php if($this->form->getElement('output_sound_device') != null){?>
|
||||
<dt id="hardwareOut-label">
|
||||
<label class="required">
|
||||
<?php echo $this->form->getElement('output_sound_device')->getLabel() ?> :
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="hardwareOut-element">
|
||||
<?php echo $this->form->getElement('output_sound_device') ?>
|
||||
</dd>
|
||||
<dt id="hardwareOutType-label">
|
||||
<label class="required">
|
||||
<?php echo $this->form->getElement('output_sound_device_type')->getLabel() ?> :
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="hardwareOutType-element">
|
||||
<?php echo $this->form->getElement('output_sound_device_type') ?>
|
||||
</dd>
|
||||
<?php } ?>
|
||||
<dt id="vorbisMetadata-label">
|
||||
<label class="required">
|
||||
<?php echo $this->form->getElement('icecast_vorbis_metadata')->getLabel() ?> :
|
||||
<span class='icecast_metadata_help_icon'></span>
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="vorbisMetadata-element">
|
||||
<?php echo $this->form->getElement('icecast_vorbis_metadata') ?>
|
||||
</dd>
|
||||
<h3><?php echo _("Global") ?></h3>
|
||||
<fieldset class="padded stream-setting-global">
|
||||
<dl class="zend_form">
|
||||
<?php if ($this->form->getElement('output_sound_device') != null) { ?>
|
||||
<dt id="hardwareOut-label">
|
||||
<label class="required">
|
||||
<?php echo $this->form->getElement('output_sound_device')->getLabel() ?> :
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="hardwareOut-element">
|
||||
<?php echo $this->form->getElement('output_sound_device') ?>
|
||||
</dd>
|
||||
<dt id="hardwareOutType-label">
|
||||
<label class="required">
|
||||
<?php echo $this->form->getElement('output_sound_device_type')->getLabel() ?> :
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="hardwareOutType-element">
|
||||
<?php echo $this->form->getElement('output_sound_device_type') ?>
|
||||
</dd>
|
||||
<?php } ?>
|
||||
<dt id="vorbisMetadata-label">
|
||||
<label class="required">
|
||||
<?php echo $this->form->getElement('icecast_vorbis_metadata')->getLabel() ?> :
|
||||
<span class='icecast_metadata_help_icon'></span>
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="vorbisMetadata-element">
|
||||
<?php echo $this->form->getElement('icecast_vorbis_metadata') ?>
|
||||
</dd>
|
||||
|
||||
<dt id="streamFormat-label">
|
||||
<label class="optional"><?php echo $this->form->getElement('streamFormat')->getLabel() ?></label>
|
||||
</dt>
|
||||
<br>
|
||||
<dd id="streamFormat-element" class="radio-inline-list">
|
||||
<?php $i=0;
|
||||
$value = $this->form->getElement('streamFormat')->getValue();
|
||||
<dt id="streamFormat-label">
|
||||
<label class="optional"><?php echo $this->form->getElement('streamFormat')->getLabel() ?></label>
|
||||
</dt>
|
||||
<br>
|
||||
<dd id="streamFormat-element" class="radio-inline-list">
|
||||
<?php $i = 0;
|
||||
$value = $this->form->getElement('streamFormat')->getValue();
|
||||
?>
|
||||
<?php foreach ($this->form->getElement('streamFormat')->getMultiOptions() as $radio) : ?>
|
||||
<label for="streamFormat-<?php echo $i ?>">
|
||||
<input type="radio" value="<?php echo $i ?>" id="streamFormat-<?php echo $i ?>" name="streamFormat" <?php if ($i == $value) {
|
||||
echo 'checked="checked"';
|
||||
} ?>>
|
||||
<?php echo $radio ?> <br><br>
|
||||
</input>
|
||||
</label>
|
||||
<?php $i = $i + 1; ?>
|
||||
<?php endforeach; ?>
|
||||
<?php if ($this->form->getElement('streamFormat')->hasErrors()) : ?>
|
||||
<ul class='errors'>
|
||||
<?php foreach ($this->form->getElement('streamFormat')->getMessages() as $error) : ?>
|
||||
<li><?php echo $error; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
</dd>
|
||||
<dt id="offAirMeta-label">
|
||||
<label>
|
||||
<?php echo $this->form->getElement('offAirMeta')->getLabel() ?> :
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="offAirMeta-element">
|
||||
<?php echo $this->form->getElement('offAirMeta') ?>
|
||||
</dd>
|
||||
<dt id="enableReplayGain-label">
|
||||
<label>
|
||||
<?php echo $this->form->getElement('enableReplayGain')->getLabel() ?> :
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="enableReplayGain-element">
|
||||
<?php echo $this->form->getElement('enableReplayGain') ?>
|
||||
</dd>
|
||||
<dt id="replayGainModifier-label" class="block-display">
|
||||
<label><?php echo $this->form->getElement('replayGainModifier')->getLabel() ?>:
|
||||
</label>
|
||||
<span id="rg_modifier_value" style="border: 0; color: #f6931f; font-weight: bold;">
|
||||
<?php echo $this->form->getElement('replayGainModifier')->getValue() ?>
|
||||
</span>
|
||||
<?php echo _("dB") ?>
|
||||
</dt>
|
||||
<dd id="replayGainModifier-element" class="block-display">
|
||||
<?php echo $this->form->getElement('replayGainModifier') ?>
|
||||
<?php if ($this->form->getElement('replayGainModifier')->hasErrors()) : ?>
|
||||
<ul class='errors'>
|
||||
<?php foreach ($this->form->getElement('replayGainModifier')->getMessages() as $error) : ?>
|
||||
<li><?php echo $error; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
<div id="slider-range-max" style="width: 99%"></div>
|
||||
</dd>
|
||||
</dl>
|
||||
</fieldset>
|
||||
<?php echo $this->form->getSubform('live_stream_subform'); ?>
|
||||
</div>
|
||||
<div style="float: left; width: 48%;">
|
||||
<h3><?php echo _("Output Streams") ?></h3>
|
||||
<fieldset class="padded">
|
||||
<?php
|
||||
// TODO: replace this with something that looks good
|
||||
echo $this->form->getElement('customStreamSettings')->render();
|
||||
for ($i = 1; $i <= $this->num_stream; $i++) {
|
||||
echo $this->form->getSubform("s" . $i . "_subform");
|
||||
}
|
||||
?>
|
||||
<?php foreach ($this->form->getElement('streamFormat')->getMultiOptions() as $radio) : ?>
|
||||
<label for="streamFormat-<?php echo $i ?>">
|
||||
<input type="radio" value="<?php echo $i ?>" id="streamFormat-<?php echo $i ?>" name="streamFormat" <?php if($i == $value){echo 'checked="checked"';}?> >
|
||||
<?php echo $radio ?> <br><br>
|
||||
</input>
|
||||
</label>
|
||||
<?php $i = $i + 1; ?>
|
||||
<?php endforeach; ?>
|
||||
<?php if($this->form->getElement('streamFormat')->hasErrors()) : ?>
|
||||
<ul class='errors'>
|
||||
<?php foreach($this->form->getElement('streamFormat')->getMessages() as $error): ?>
|
||||
<li><?php echo $error; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
</dd>
|
||||
<dt id="offAirMeta-label">
|
||||
<label>
|
||||
<?php echo $this->form->getElement('offAirMeta')->getLabel() ?> :
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="offAirMeta-element">
|
||||
<?php echo $this->form->getElement('offAirMeta') ?>
|
||||
</dd>
|
||||
<dt id="enableReplayGain-label">
|
||||
<label>
|
||||
<?php echo $this->form->getElement('enableReplayGain')->getLabel() ?> :
|
||||
</label>
|
||||
</dt>
|
||||
<dd id="enableReplayGain-element">
|
||||
<?php echo $this->form->getElement('enableReplayGain') ?>
|
||||
</dd>
|
||||
<dt id="replayGainModifier-label" class="block-display">
|
||||
<label><?php echo $this->form->getElement('replayGainModifier')->getLabel() ?>:
|
||||
</label>
|
||||
<span id="rg_modifier_value" style="border: 0; color: #f6931f; font-weight: bold;">
|
||||
<?php echo $this->form->getElement('replayGainModifier')->getValue() ?>
|
||||
</span>
|
||||
<?php echo _("dB")?>
|
||||
</dt>
|
||||
<dd id="replayGainModifier-element" class="block-display">
|
||||
<?php echo $this->form->getElement('replayGainModifier') ?>
|
||||
<?php if($this->form->getElement('replayGainModifier')->hasErrors()) : ?>
|
||||
<ul class='errors'>
|
||||
<?php foreach($this->form->getElement('replayGainModifier')->getMessages() as $error): ?>
|
||||
<li><?php echo $error; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
<div id="slider-range-max" style="width: 99%"></div>
|
||||
</dd>
|
||||
</dl>
|
||||
</fieldset>
|
||||
<?php echo $this->form->getSubform('live_stream_subform'); ?>
|
||||
</div>
|
||||
<div style="float: left; width: 48%;">
|
||||
<h3><?php echo _("Output Streams") ?></h3>
|
||||
<fieldset class="padded">
|
||||
<?php
|
||||
// TODO: replace this with something that looks good
|
||||
echo $this->form->getElement('customStreamSettings')->render();
|
||||
for($i=1;$i<=$this->num_stream;$i++){
|
||||
echo $this->form->getSubform("s".$i."_subform");
|
||||
}
|
||||
?>
|
||||
</fieldset>
|
||||
<br />
|
||||
<div style="clear: both"></div>
|
||||
<button name="stream_save" id="stream_save_bottom" type="button" class="btn right-floated"><?php echo _("Save") ?></button>
|
||||
</div>
|
||||
</fieldset>
|
||||
<br />
|
||||
<div style="clear: both"></div>
|
||||
<button name="stream_save" id="stream_save_bottom" type="button" class="btn right-floated"><?php echo _("Save") ?></button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue