Fix HTML iframe tag in EmbedController(s) and adopt relative URLs

This changeset fixes this issue:
* https://github.com/LibreTime/libretime/issues/988

This changeset contributes in fixing this issue:
* https://github.com/LibreTime/libretime/issues/957
This commit is contained in:
Valerio Bozzolan 2020-11-28 18:47:56 +01:00
parent f62ed7d2e3
commit b8f4a33927
2 changed files with 15 additions and 15 deletions

View file

@ -25,18 +25,18 @@ class EmbedController extends Zend_Controller_Action
$request = $this->getRequest();
$this->view->playerhtml5_js = Application_Common_HTTPHelper::getStationUrl() . "js/airtime/player/playerhtml5.js?".$CC_CONFIG['airtime_version'];
$this->view->jquery = Application_Common_HTTPHelper::getStationUrl() . "js/libs/jquery-1.10.2.js";
$this->view->metadata_api_url = Application_Common_HTTPHelper::getStationUrl() . "api/live-info";
$this->view->playerhtml5_js = "/js/airtime/player/playerhtml5.js?".$CC_CONFIG['airtime_version'];
$this->view->jquery = "/js/libs/jquery-1.10.2.js";
$this->view->metadata_api_url = "/api/live-info";
$this->view->player_title = json_encode($this->view->escape($request->getParam('title')));
$this->view->jquery_i18n = Application_Common_HTTPHelper::getStationUrl() . "js/i18n/jquery.i18n.js?";
$this->view->jquery_i18n = "/js/i18n/jquery.i18n.js?";
$styleParam = $request->getParam('style');
$player_style = isset($styleParam) ? $styleParam : "basic";
if ($player_style == "premium") {
$this->view->css = Application_Common_HTTPHelper::getStationUrl() . "css/radio-page/premium_player.css?".$CC_CONFIG['airtime_version'];
$this->view->css = "/css/radio-page/premium_player.css?".$CC_CONFIG['airtime_version'];
} else {
$this->view->css = Application_Common_HTTPHelper::getStationUrl() . "css/player.css?".$CC_CONFIG['airtime_version'];
$this->view->css = "/css/player.css?".$CC_CONFIG['airtime_version'];
}
$this->view->player_style = $player_style;
@ -75,10 +75,10 @@ class EmbedController extends Zend_Controller_Action
$CC_CONFIG = Config::getConfig();
$this->view->css = Application_Common_HTTPHelper::getStationUrl() . "widgets/css/airtime-widgets.css?".$CC_CONFIG['airtime_version'];
$this->view->jquery = Application_Common_HTTPHelper::getStationUrl() . "widgets/js/jquery-1.6.1.min.js?".$CC_CONFIG['airtime_version'];
$this->view->jquery_custom = Application_Common_HTTPHelper::getStationUrl() . "widgets/js/jquery-ui-1.8.10.custom.min.js?".$CC_CONFIG['airtime_version'];
$this->view->widget_js = Application_Common_HTTPHelper::getStationUrl() . "widgets/js/jquery.showinfo.js?".$CC_CONFIG['airtime_version'];
$this->view->css = "/widgets/css/airtime-widgets.css?".$CC_CONFIG['airtime_version'];
$this->view->jquery = "/widgets/js/jquery-1.6.1.min.js?".$CC_CONFIG['airtime_version'];
$this->view->jquery_custom = "/widgets/js/jquery-ui-1.8.10.custom.min.js?".$CC_CONFIG['airtime_version'];
$this->view->widget_js = "/widgets/js/jquery.showinfo.js?".$CC_CONFIG['airtime_version'];
}
public function weeklyProgramAction()
@ -93,12 +93,12 @@ class EmbedController extends Zend_Controller_Action
$widgetStyle = $request->getParam('style');
if ($widgetStyle == "premium") {
$this->view->widgetStyle = "premium";
$this->view->css = Application_Common_HTTPHelper::getStationUrl() . "/css/embed/weekly-schedule-widget.css?" . $CC_CONFIG['airtime_version'];
$this->view->css = "/css/embed/weekly-schedule-widget.css?" . $CC_CONFIG['airtime_version'];
} else {
$this->view->widgetStyle = "basic";
$this->view->css = Application_Common_HTTPHelper::getStationUrl() . "/css/embed/weekly-schedule-widget-basic.css?" . $CC_CONFIG['airtime_version'];
$this->view->css = "/css/embed/weekly-schedule-widget-basic.css?" . $CC_CONFIG['airtime_version'];
}
$this->view->jquery = Application_Common_HTTPHelper::getStationUrl() . "widgets/js/jquery-1.6.1.min.js?".$CC_CONFIG['airtime_version'];
$this->view->jquery = "/widgets/js/jquery-1.6.1.min.js?".$CC_CONFIG['airtime_version'];
$weeklyScheduleData = WidgetHelper::getWeekInfoV2();