mirror of
https://github.com/Yetangitu/ampache
synced 2025-10-03 01:39:28 +02:00
Rename HTML5 Player to Web Player
This commit is contained in:
parent
6a95f51b68
commit
e35f175a4b
14 changed files with 25 additions and 25 deletions
|
@ -65,7 +65,7 @@ switch ($_GET['thumb']) {
|
||||||
$size['width'] = '80';
|
$size['width'] = '80';
|
||||||
break;
|
break;
|
||||||
case '4':
|
case '4':
|
||||||
/* HTML5 Player size */
|
/* Web Player size */
|
||||||
$size['height'] = 200;
|
$size['height'] = 200;
|
||||||
$size['width'] = 200; // 200px width, set via CSS
|
$size['width'] = 200; // 200px width, set via CSS
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -162,7 +162,7 @@ class Stream_Playlist
|
||||||
case 'download':
|
case 'download':
|
||||||
case 'democratic':
|
case 'democratic':
|
||||||
case 'localplay':
|
case 'localplay':
|
||||||
case 'html5_player':
|
case 'web_player':
|
||||||
// These are valid, but witchy
|
// These are valid, but witchy
|
||||||
$redirect = false;
|
$redirect = false;
|
||||||
unset($ext);
|
unset($ext);
|
||||||
|
@ -356,19 +356,19 @@ class Stream_Playlist
|
||||||
} // create_xspf
|
} // create_xspf
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* create_html5_player
|
* create_web_player
|
||||||
*
|
*
|
||||||
* Creates an html5 player.
|
* Creates an web player.
|
||||||
*/
|
*/
|
||||||
public function create_html5_player()
|
public function create_web_player()
|
||||||
{
|
{
|
||||||
if (Config::get("iframes")) {
|
if (Config::get("iframes")) {
|
||||||
require Config::get('prefix') . '/templates/create_html5_player_embedded.inc.php';
|
require Config::get('prefix') . '/templates/create_web_player_embedded.inc.php';
|
||||||
} else {
|
} else {
|
||||||
require Config::get('prefix') . '/templates/create_html5_player.inc.php';
|
require Config::get('prefix') . '/templates/create_web_player.inc.php';
|
||||||
}
|
}
|
||||||
|
|
||||||
} // create_html5_player
|
} // create_web_player
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* create_localplay
|
* create_localplay
|
||||||
|
|
|
@ -308,7 +308,7 @@ class Update
|
||||||
$update_string = '- Catalog types are plugins now.<br />';
|
$update_string = '- Catalog types are plugins now.<br />';
|
||||||
$version[] = array('version' => '360020', 'description' => $update_string);
|
$version[] = array('version' => '360020', 'description' => $update_string);
|
||||||
|
|
||||||
$update_string = '- Add insertion date on Now Playing and option to show the current song in page title for HTML5 player.<br />';
|
$update_string = '- Add insertion date on Now Playing and option to show the current song in page title for Web player.<br />';
|
||||||
$version[] = array('version' => '360021', 'description' => $update_string);
|
$version[] = array('version' => '360021', 'description' => $update_string);
|
||||||
|
|
||||||
return $version;
|
return $version;
|
||||||
|
@ -1677,7 +1677,7 @@ class Update
|
||||||
/**
|
/**
|
||||||
* update_360021
|
* update_360021
|
||||||
*
|
*
|
||||||
* Add insertion date on Now Playing and option to show the current song in page title for HTML5 player
|
* Add insertion date on Now Playing and option to show the current song in page title for Web player
|
||||||
*/
|
*/
|
||||||
public static function update_360021()
|
public static function update_360021()
|
||||||
{
|
{
|
||||||
|
@ -1685,7 +1685,7 @@ class Update
|
||||||
Dba::write($sql);
|
Dba::write($sql);
|
||||||
|
|
||||||
$sql = "INSERT INTO `preference` (`name`,`value`,`description`,`level`,`type`,`catagory`) " .
|
$sql = "INSERT INTO `preference` (`name`,`value`,`description`,`level`,`type`,`catagory`) " .
|
||||||
"VALUES ('song_page_title','0','Show current song in HTML5 player page title',25,'string','interface')";
|
"VALUES ('song_page_title','0','Show current song in Web player page title',25,'string','interface')";
|
||||||
$retval = Dba::write($sql);
|
$retval = Dba::write($sql);
|
||||||
|
|
||||||
$id = Dba::insert_id();
|
$id = Dba::insert_id();
|
||||||
|
|
|
@ -173,7 +173,7 @@ function create_preference_input($name,$value)
|
||||||
echo "</select>\n";
|
echo "</select>\n";
|
||||||
break;
|
break;
|
||||||
case 'play_type':
|
case 'play_type':
|
||||||
if ($value == 'localplay') { $is_local = 'selected="selected"'; } elseif ($value == 'democratic') { $is_vote = 'selected="selected"'; } elseif ($value == 'html5_player') { $is_html5_player = 'selected="selected"'; } else { $is_stream = "selected=\"selected\""; }
|
if ($value == 'localplay') { $is_local = 'selected="selected"'; } elseif ($value == 'democratic') { $is_vote = 'selected="selected"'; } elseif ($value == 'web_player') { $is_web_player = 'selected="selected"'; } else { $is_stream = "selected=\"selected\""; }
|
||||||
echo "<select name=\"$name\">\n";
|
echo "<select name=\"$name\">\n";
|
||||||
echo "\t<option value=\"\">" . T_('None') . "</option>\n";
|
echo "\t<option value=\"\">" . T_('None') . "</option>\n";
|
||||||
if (Config::get('allow_stream_playback')) {
|
if (Config::get('allow_stream_playback')) {
|
||||||
|
@ -185,7 +185,7 @@ function create_preference_input($name,$value)
|
||||||
if (Config::get('allow_localplay_playback')) {
|
if (Config::get('allow_localplay_playback')) {
|
||||||
echo "\t<option value=\"localplay\" $is_local>" . T_('Localplay') . "</option>\n";
|
echo "\t<option value=\"localplay\" $is_local>" . T_('Localplay') . "</option>\n";
|
||||||
}
|
}
|
||||||
echo "\t<option value=\"html5_player\" $is_html5_player>" . _('HTML5 Player') . "</option>\n";
|
echo "\t<option value=\"web_player\" $is_web_player>" . _('Web Player') . "</option>\n";
|
||||||
echo "</select>\n";
|
echo "</select>\n";
|
||||||
break;
|
break;
|
||||||
case 'playlist_type':
|
case 'playlist_type':
|
||||||
|
|
|
@ -45,7 +45,7 @@ switch ($_REQUEST['action']) {
|
||||||
}
|
}
|
||||||
$new = $_POST['type'];
|
$new = $_POST['type'];
|
||||||
break;
|
break;
|
||||||
case 'html5_player':
|
case 'web_player':
|
||||||
$new = $_POST['type'];
|
$new = $_POST['type'];
|
||||||
// Rien a faire
|
// Rien a faire
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -28,13 +28,13 @@
|
||||||
<!-- begin
|
<!-- begin
|
||||||
function PlayerPopUp(URL)
|
function PlayerPopUp(URL)
|
||||||
{
|
{
|
||||||
window.open(URL, 'HTML5_player', 'width=730,height=285,scrollbars=0,toolbar=0,location=0,directories=0,status=0,resizable=0');
|
window.open(URL, 'Web_player', 'width=730,height=285,scrollbars=0,toolbar=0,location=0,directories=0,status=0,resizable=0');
|
||||||
window.location = '<?php echo return_referer() ?>';
|
window.location = '<?php echo return_referer() ?>';
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
// end -->
|
// end -->
|
||||||
</script>
|
</script>
|
||||||
</head>
|
</head>
|
||||||
<body onLoad="javascript:PlayerPopUp('<?php echo Config::get('web_path')?>/html5_player.php<?php echo '?playlist_id=' . $this->id ?>')">
|
<body onLoad="javascript:PlayerPopUp('<?php echo Config::get('web_path')?>/web_player.php<?php echo '?playlist_id=' . $this->id ?>')">
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -41,6 +41,6 @@ function PlayerFrame(URL)
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
</head>
|
</head>
|
||||||
<body onLoad="javascript:PlayerFrame('<?php echo Config::get('web_path')?>/html5_player_embedded.php<?php echo '?playlist_id=' . $this->id ?>');">
|
<body onLoad="javascript:PlayerFrame('<?php echo Config::get('web_path')?>/web_player_embedded.php<?php echo '?playlist_id=' . $this->id ?>');">
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
|
@ -50,7 +50,7 @@ if (Config::get('use_rss')) { ?>
|
||||||
<script src="<?php echo $web_path; ?>/lib/javascript/ajax.js" language="javascript" type="text/javascript"></script>
|
<script src="<?php echo $web_path; ?>/lib/javascript/ajax.js" language="javascript" type="text/javascript"></script>
|
||||||
<script src="<?php echo $web_path; ?>/lib/javascript/edit-dialog.js" language="javascript" type="text/javascript"></script>
|
<script src="<?php echo $web_path; ?>/lib/javascript/edit-dialog.js" language="javascript" type="text/javascript"></script>
|
||||||
<?php
|
<?php
|
||||||
// If iframes, we check in javascript that parent container exist, otherwise we redirect to index. Otherwise HTML5 iframed Player will look broken.
|
// If iframes, we check in javascript that parent container exist, otherwise we redirect to index. Otherwise iframed Web Player will look broken.
|
||||||
if (Config::get('iframes') && $_SERVER['REQUEST_METHOD'] != 'POST') {
|
if (Config::get('iframes') && $_SERVER['REQUEST_METHOD'] != 'POST') {
|
||||||
?>
|
?>
|
||||||
<script language="javascript" type="text/javascript">
|
<script language="javascript" type="text/javascript">
|
||||||
|
|
|
@ -36,7 +36,7 @@ if (Preference::has_access('play_type')) {
|
||||||
<?php } if (Config::get('allow_democratic_playback')) { ?>
|
<?php } if (Config::get('allow_democratic_playback')) { ?>
|
||||||
<option value="democratic" <?php echo $is_democratic; ?>><?php echo T_('Democratic'); ?></option>
|
<option value="democratic" <?php echo $is_democratic; ?>><?php echo T_('Democratic'); ?></option>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
<option value="html5_player" <?php echo $is_html5_player; ?>><?php echo T_('HTML5 Player'); ?></option>
|
<option value="web_player" <?php echo $is_web_player; ?>><?php echo T_('Web Player'); ?></option>
|
||||||
</select>
|
</select>
|
||||||
<?php echo Ajax::observe('play_type_select','change',Ajax::action('?page=stream&action=set_play_type','play_type_select','play_type_form'),'1'); ?>
|
<?php echo Ajax::observe('play_type_select','change',Ajax::action('?page=stream&action=set_play_type','play_type_select','play_type_form'),'1'); ?>
|
||||||
</form>
|
</form>
|
||||||
|
|
|
@ -738,9 +738,9 @@ td.lp_current a {
|
||||||
}
|
}
|
||||||
|
|
||||||
/************************************************/
|
/************************************************/
|
||||||
/* HTML5 Player */
|
/* Web Player */
|
||||||
/************************************************/
|
/************************************************/
|
||||||
#html5_player #playlist
|
#web_player #playlist
|
||||||
{
|
{
|
||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
|
|
|
@ -1096,9 +1096,9 @@ table.tabledata .cel_php_setting, table.tabledata .cel_configuration, .cel_prefe
|
||||||
}
|
}
|
||||||
|
|
||||||
/************************************************/
|
/************************************************/
|
||||||
/* HTML5 Player */
|
/* Web Player */
|
||||||
/************************************************/
|
/************************************************/
|
||||||
#html5_player #playlist
|
#web_player #playlist
|
||||||
{
|
{
|
||||||
overflow-x: hidden;
|
overflow-x: hidden;
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
|
|
|
@ -22,4 +22,4 @@
|
||||||
|
|
||||||
require_once 'lib/init.php';
|
require_once 'lib/init.php';
|
||||||
|
|
||||||
require_once Config::get('prefix') . '/templates/show_html5_player.inc.php';
|
require_once Config::get('prefix') . '/templates/show_web_player.inc.php';
|
|
@ -23,4 +23,4 @@
|
||||||
require_once 'lib/init.php';
|
require_once 'lib/init.php';
|
||||||
|
|
||||||
$iframed = true;
|
$iframed = true;
|
||||||
require_once Config::get('prefix') . '/templates/show_html5_player.inc.php';
|
require_once Config::get('prefix') . '/templates/show_web_player.inc.php';
|
Loading…
Add table
Add a link
Reference in a new issue