summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKarl 'vollmerk' Vollmer <vollmer@ampache.org>2007-01-06 20:59:26 +0000
committerKarl 'vollmerk' Vollmer <vollmer@ampache.org>2007-01-06 20:59:26 +0000
commite73e55333452ce5615c21f27f323cc94bb8654bc (patch)
treec7b6dd77684623d2461a77055f2b9608885f5570
parentdb638040c7d6ee38187ffa9a99d083449e9669a3 (diff)
downloadampache-e73e55333452ce5615c21f27f323cc94bb8654bc.tar.gz
ampache-e73e55333452ce5615c21f27f323cc94bb8654bc.tar.bz2
ampache-e73e55333452ce5615c21f27f323cc94bb8654bc.zip
* Fixed display issues on TV page relating to
now playing Post AJAX and floating issues * Fixed display of Last IP if tracking disabled * Fixed play issue with invalid songs when using Democratic Play
-rwxr-xr-xdocs/CHANGELOG6
-rw-r--r--lib/class/song.class.php2
-rw-r--r--lib/class/update.class.php2
-rw-r--r--play/index.php7
-rw-r--r--templates/show_tv.inc.php2
-rw-r--r--templates/show_tv_nowplaying.inc.php3
-rw-r--r--templates/show_users.inc7
-rw-r--r--themes/burgundy/templates/default.css8
-rw-r--r--themes/classic/templates/default.css9
-rw-r--r--themes/greyblock/templates/default.css9
10 files changed, 43 insertions, 12 deletions
diff --git a/docs/CHANGELOG b/docs/CHANGELOG
index 8d3c8604..79b41f1e 100755
--- a/docs/CHANGELOG
+++ b/docs/CHANGELOG
@@ -4,6 +4,12 @@
--------------------------------------------------------------------------
v.3.3.3
+ - Fixed play lock with Democratic Play if song no longer exists
+ - Fixed a display issue of the Now Playing on the Democratic
+ play page
+ - Fixed display of Last IP if track_user_ip was disabled
+ - Fixed Update to redirect to test.php if no db connection found
+ (Thx SpComb)
- Fixed an issue that caused AJAX not to work if you were working
in a sub-directory.
diff --git a/lib/class/song.class.php b/lib/class/song.class.php
index 242186ad..60a9da1f 100644
--- a/lib/class/song.class.php
+++ b/lib/class/song.class.php
@@ -182,7 +182,7 @@ class Song {
$this->mime = "audio/x-realaudio";
break;
case 'flac';
- $this->mime = "application/x-flac";
+ $this->mime = "audio/x-flac";
break;
case 'wv':
$this->mime = 'audio/x-wavpack';
diff --git a/lib/class/update.class.php b/lib/class/update.class.php
index 8ea8a615..a11108fe 100644
--- a/lib/class/update.class.php
+++ b/lib/class/update.class.php
@@ -83,6 +83,8 @@ class Update {
/* Make sure that update_info exits */
$sql = "SHOW TABLES LIKE 'update_info'";
$db_results = mysql_query($sql, dbh());
+ if (!is_resource(dbh())) { header("Location: test.php"); }
+
// If no table
if (!mysql_num_rows($db_results)) {
diff --git a/play/index.php b/play/index.php
index 95f92344..8e07e6d2 100644
--- a/play/index.php
+++ b/play/index.php
@@ -120,6 +120,13 @@ if (make_bool($GLOBALS['user']->disabled)) {
/* If we don't have a file, or the file is not readable */
if (!$song->file OR ( !is_readable($song->file) AND $catalog->catalog_type != 'remote' ) ) {
+
+ // We need to make sure this isn't democratic play, if it is then remove the song
+ // from the vote list
+ if (is_object($tmp_playlist)) {
+ $tmp_playlist->delete_track($song_id);
+ }
+
debug_event('file_not_found',"Error song ($song->title) does not have a valid filename specified",'2');
echo "Error: Invalid Song Specified, file not found or file unreadable";
exit;
diff --git a/templates/show_tv.inc.php b/templates/show_tv.inc.php
index 0db5f423..567e8ce8 100644
--- a/templates/show_tv.inc.php
+++ b/templates/show_tv.inc.php
@@ -25,12 +25,10 @@ $location = get_location();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $htmllang; ?>" lang="<?php echo $htmllang; ?>">
-
<head>
<link rel="shortcut icon" href="<?php echo $web_path; ?>/favicon.ico" />
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo conf('site_charset'); ?>" />
<title><?php echo conf('site_title'); ?> - <?php echo $location['title']; ?></title>
-<link rel="stylesheet" href="<?php echo $web_path; ?>/templates/default.css" type="text/css" />
<link rel="stylesheet" href="<?php echo $web_path; ?><?php echo conf('theme_path'); ?>/templates/default.css" type="text/css" />
</head>
<body>
diff --git a/templates/show_tv_nowplaying.inc.php b/templates/show_tv_nowplaying.inc.php
index 94e4dee2..10cf1f43 100644
--- a/templates/show_tv_nowplaying.inc.php
+++ b/templates/show_tv_nowplaying.inc.php
@@ -20,6 +20,7 @@
*/
/* Pull the Now Playing Information */
$results = get_now_playing();
+$web_path = conf('web_path');
?>
<table cellpadding="0">
<?php
@@ -31,7 +32,7 @@ foreach ($results as $row) {
<tr>
<td>
<a target="_blank" href="<?php echo $web_path; ?>/image.php?id=<?php echo $row['song']->album; ?>&amp;type=popup&amp;sid=<?php echo session_id(); ?>" onclick="popup_art('<?php echo $web_path; ?>/image.php?id=<?php echo $row['song']->album; ?>&amp;type=popup&amp;sid=<?php echo session_id(); ?>'); return false;">
- <img align="middle" border="0" src="<?php echo $web_path; ?>/image.php?id=<?php echo $row['song']->album; ?>&amp;fast=1" />
+ <img align="middle" border="0" src="<?php echo $web_path; ?>/image.php?id=<?php echo $row['song']->album; ?>&amp;fast=1" width="275" height="275" />
</a>
</td>
</tr>
diff --git a/templates/show_users.inc b/templates/show_users.inc
index 6b7d3e14..b92afb11 100644
--- a/templates/show_users.inc
+++ b/templates/show_users.inc
@@ -56,10 +56,11 @@ $admin_menu = "admin/";
<td align="center">
<b><?php echo _('Activity'); ?></b>
</td>
+ <?php if (conf('track_user_ip')) { ?>
<td align="center">
<b><?php echo _('Last Ip'); ?></b>
</td>
-
+ <?php } ?>
<td colspan="5">&nbsp;</td>
<td align="center">
<b><?php echo _('On-line'); ?></b>
@@ -91,13 +92,13 @@ while ($results = mysql_fetch_object($db_result)) {
<td>
<?php echo $user->f_useage; ?>
</td>
+ <?php if (conf('track_user_ip')) { ?>
<td>
<a href="<?php echo $web_path; ?>/admin/users.php?action=show_ip_history&amp;user_id=<?php echo $user->id; ?>">
<?php echo $user->ip_history; ?>
</a>
</td>
-
-
+ <?php } ?>
<td>
<a href="<?php echo $web_path; ?>/admin/users.php?action=edit&amp;user=<?php echo $user->id; ?>">
<?php echo get_user_icon('edit'); ?>
diff --git a/themes/burgundy/templates/default.css b/themes/burgundy/templates/default.css
index 4dc6e8e3..c9d337ed 100644
--- a/themes/burgundy/templates/default.css
+++ b/themes/burgundy/templates/default.css
@@ -523,6 +523,14 @@ margin-right:5em;
border-bottom: 1px solid #ffffcc;
}
+#tv_left {
+ float: left;
+ clear: left;
+}
+#tv_np {
+ float: right;
+}
+
/* styles for the star ratings */
.star-rating{
list-style:none;
diff --git a/themes/classic/templates/default.css b/themes/classic/templates/default.css
index 406f3583..8ab922e6 100644
--- a/themes/classic/templates/default.css
+++ b/themes/classic/templates/default.css
@@ -601,14 +601,13 @@ margin-right:5em;
/* TV Page Related Styles */
-#tv_control {
- float:left;
-}
-
#tv_np {
float:right;
}
-
+#tv_left {
+ float: left;
+ clear right;
+}
#tv_playlist {
clear: both;
}
diff --git a/themes/greyblock/templates/default.css b/themes/greyblock/templates/default.css
index bf646cf7..8e1bb4f2 100644
--- a/themes/greyblock/templates/default.css
+++ b/themes/greyblock/templates/default.css
@@ -328,6 +328,15 @@
{
float: left;
}
+
+#tv_left {
+ float: left;
+ clear: left;
+}
+#tv_np {
+ float: right;
+}
+
/* styles for the star ratings */
.star-rating{
list-style:none;