PHP JSON генерация страниц под ForkPlayer: различия между версиями
Prof (обсуждение | вклад) Нет описания правки |
Prof (обсуждение | вклад) Нет описания правки |
||
(не показана 1 промежуточная версия этого же участника) | |||
Строка 1: | Строка 1: | ||
В playlist_url ссылки на страницы | В playlist_url ссылки на страницы | ||
В stream_url на видеофайлы, moonwalk iframe видео плеер и т.д. | В stream_url на видеофайлы, moonwalk iframe видео плеер и т.д.<blockquote><?php</blockquote><blockquote>$_CH[]=["title"=>"1 c","playlist_url"=>"","stream_url"=>"","description"=>""]; | ||
$_CH[]=["title"=>"2 c","playlist_url"=>"","stream_url"=>"","description"=>""]; | |||
$_CH[]=["title"=>"3 c","playlist_url"=>"","stream_url"=>"","description"=>""];</blockquote><blockquote>$_PL["background_image"]=$sitebackground;</blockquote><blockquote>$_PL["icon"]=$siteicon;</blockquote><blockquote>$_PL["channels"]=$_CH;</blockquote><blockquote>if(!empty($sitechbkg)) $_PL["style"]["site"]["channels"]["default"]["background"]="none"; | |||
</blockquote><blockquote>if(!empty($sitecolor)) { | |||
$_PL["style"]["site"]["channels"]["default"]["color"]=$sitecolor; | |||
$_PL["style"]["site"]["infoList"]["color"]=$sitecolor;</blockquote><blockquote>}</blockquote><blockquote>if(!empty($sitechbkg)) $_PL["style"]["site"]["channels"]["selected"]["background"]="none $sitechbkg"; | |||
if(!empty($sitechcolor)) $_PL["style"]["site"]["channels"]["selected"]["color"]=$sitechcolor;</blockquote><blockquote>print json_encode($_PL);</blockquote> | |||
<br /> | |||
</ |
Текущая версия от 22:05, 19 февраля 2019
В playlist_url ссылки на страницы
В stream_url на видеофайлы, moonwalk iframe видео плеер и т.д.
<?php
$_CH[]=["title"=>"1 c","playlist_url"=>"","stream_url"=>"","description"=>""];
$_CH[]=["title"=>"2 c","playlist_url"=>"","stream_url"=>"","description"=>""];
$_CH[]=["title"=>"3 c","playlist_url"=>"","stream_url"=>"","description"=>""];
$_PL["background_image"]=$sitebackground;
$_PL["icon"]=$siteicon;
$_PL["channels"]=$_CH;
if(!empty($sitechbkg)) $_PL["style"]["site"]["channels"]["default"]["background"]="none";
if(!empty($sitecolor)) {
$_PL["style"]["site"]["channels"]["default"]["color"]=$sitecolor;
$_PL["style"]["site"]["infoList"]["color"]=$sitecolor;
}
if(!empty($sitechbkg)) $_PL["style"]["site"]["channels"]["selected"]["background"]="none $sitechbkg"; if(!empty($sitechcolor)) $_PL["style"]["site"]["channels"]["selected"]["color"]=$sitechcolor;
print json_encode($_PL);