summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKarl 'vollmerk' Vollmer <vollmer@ampache.org>2005-06-25 17:28:50 +0000
committerKarl 'vollmerk' Vollmer <vollmer@ampache.org>2005-06-25 17:28:50 +0000
commit2398133cc42045805e6045935efeefee18ab1ad8 (patch)
tree88e81a14e612cf23fe210fe1750634fbc48ae29e
parent793d3d0bf19a8007e54f8440a5412e2b6709f5b3 (diff)
downloadampache-2398133cc42045805e6045935efeefee18ab1ad8.tar.gz
ampache-2398133cc42045805e6045935efeefee18ab1ad8.tar.bz2
ampache-2398133cc42045805e6045935efeefee18ab1ad8.zip
more html cleanup
-rw-r--r--admin/mail.php2
-rw-r--r--admin/preferences.php3
-rwxr-xr-xdocs/CHANGELOG2
-rw-r--r--download/index.php3
-rw-r--r--lib/duplicates.php2
-rw-r--r--login.php7
-rw-r--r--play/pupload.php2
-rw-r--r--preferences.php2
-rw-r--r--templates/add_catalog.inc10
-rw-r--r--templates/admin_menu.inc14
-rw-r--r--templates/header.inc4
-rw-r--r--templates/javascript_refresh.inc2
-rw-r--r--templates/list_duplicates.inc13
-rw-r--r--templates/list_flagged.inc2
-rw-r--r--templates/menu.inc4
-rw-r--r--templates/show_artist.inc13
-rw-r--r--templates/show_confirmation.inc.php2
-rw-r--r--templates/show_preferences.inc2
-rw-r--r--templates/show_search.inc2
-rw-r--r--templates/show_upload.inc25
-rw-r--r--templates/tool_box.inc2
-rw-r--r--upload.php10
22 files changed, 64 insertions, 64 deletions
diff --git a/admin/mail.php b/admin/mail.php
index 4701d298..78d257a8 100644
--- a/admin/mail.php
+++ b/admin/mail.php
@@ -91,7 +91,7 @@ show_clear();
<form name="mail" method="post" action="<?php echo conf('web_path'); ?>/admin/mail.php" enctype="multipart/form-data">
-<p><font color="<?php echo $error_color; ?>"><?php echo $complete_text; ?></font></p>
+<p><font color="<?php echo conf('error_color'); ?>"><?php echo $complete_text; ?></font></p>
<table>
<tr>
diff --git a/admin/preferences.php b/admin/preferences.php
index 973fddb0..ba381f44 100644
--- a/admin/preferences.php
+++ b/admin/preferences.php
@@ -88,6 +88,3 @@ require (conf('prefix') . "/templates/show_preferences.inc");
// FOOTER
show_page_footer ('Admin', 'Admin Preferences',$user->prefs['display_menu']);
?>
-
-</body>
-</html>
diff --git a/docs/CHANGELOG b/docs/CHANGELOG
index 7c7932f4..d9128518 100755
--- a/docs/CHANGELOG
+++ b/docs/CHANGELOG
@@ -5,6 +5,8 @@
--------------------------------------------------------------------------
v.3.3.2-Alpha1:
- Added Spanish Translation (Thx ros)
+ - Fixed Menu Highlight when using a Translation
+ - More HTML cleanup (Thx Xgizzmo)
--------------------------------------------------------------------------
v.3.3.1 06/21/2005:
diff --git a/download/index.php b/download/index.php
index 25972606..c04f1563 100644
--- a/download/index.php
+++ b/download/index.php
@@ -45,8 +45,7 @@ if ($user->prefs['download']) {
$song = new Song($_REQUEST['song_id']);
$song->format_song();
$song->format_type();
- $song_name = $song->f_artist_full . " - " . $song->title . "." . $song->type;
-
+ $song_name = str_replace('"'," ",$song->f_artist_full . " - " . $song->title . "." . $song->type);
// Use Horde's Browser class to send the right headers for different browsers
// Should get the mime-type from the song rather than hard-coding it.
header("Content-Length: " . $song->size);
diff --git a/lib/duplicates.php b/lib/duplicates.php
index 202f1185..58b5a2e5 100644
--- a/lib/duplicates.php
+++ b/lib/duplicates.php
@@ -75,7 +75,7 @@ function show_duplicate_searchbox($search_type) {
?>
<br />
<form name="songs" action="<?php echo conf('web_path'); ?>/admin/duplicates.php" method="post" enctype="multipart/form-data" >
-<table class="border" cellspacing="0" cellpadding="3" border="0" width="450px">
+<table class="border" cellspacing="0" cellpadding="3" border="0" width="450">
<tr class="table-header">
<td colspan="2"><b><?php echo _("Find Duplicates"); ?></b></td>
</tr>
diff --git a/login.php b/login.php
index f3e0057b..fa476d55 100644
--- a/login.php
+++ b/login.php
@@ -78,13 +78,14 @@ if ( ($auth['success'] == 1)) {
exit();
} // auth success
-
+$htmllang = str_replace("_","-",conf('lang'));
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd">
-<html lang="<?php echo conf('lang'); ?>">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $htmllang; ?>" lang="<?php echo $htmllang; ?>">
<head>
-<meta http-equiv="Content-Type" content="text/html; charset=<?php echo conf('site_charset'); ?>" />
+<meta http-equiv="Content-Style-Type" content="text/html" charset="<?php echo conf('site_charset'); ?>" />
+<link rel="shortcut icon" href="<?php echo conf('web_path'); ?>/favicon.ico" />
<title> <?php echo conf('site_title'); ?> </title>
<?php show_template('style'); ?>
diff --git a/play/pupload.php b/play/pupload.php
index 409601ec..2290a59d 100644
--- a/play/pupload.php
+++ b/play/pupload.php
@@ -160,7 +160,7 @@ if ( $_REQUEST['action'] == 'm3u' ) {
echo "#EXTM3U\n";
$song_name = $song . " - " . $title . "." . $type;
- $song_name = $artist . " - " . $title . "." . $song->type;;
+ $song_name = $artist . " - " . $title . "." . $song->type;
echo "#EXTINF:$song_time,$title\n";
$sess = $_COOKIE[libglue_param('sess_name')];
if($temp_user->prefs['down-sample'] == 'true')
diff --git a/preferences.php b/preferences.php
index 77e03d89..f1974efa 100644
--- a/preferences.php
+++ b/preferences.php
@@ -69,5 +69,3 @@ require (conf('prefix') . "/templates/show_preferences.inc");
// FOOTER
show_page_footer ('Preferences', '',$user->prefs['display_menu']);
?>
-</body>
-</html>
diff --git a/templates/add_catalog.inc b/templates/add_catalog.inc
index 57ee6a9e..f0493269 100644
--- a/templates/add_catalog.inc
+++ b/templates/add_catalog.inc
@@ -34,7 +34,7 @@ $default_sort = "%a/%A";
<table class="tabledata" cellpadding="0" border="0" cellspacing="0">
<tr>
<td><?php echo _("Catalog Name"); ?>: </td>
- <td><input size="60" type="text" name="name" value="<?php echo $_REQUEST['name']; ?>" size="30" /></td>
+ <td><input size="60" type="text" name="name" value="<?php echo $_REQUEST['name']; ?>" /></td>
<td style="vertical-align:top; font-family: monospace;" rowspan="6">
<strong><?php echo _("Auto-inserted Fields"); ?>:</strong><br />
%A = <?php echo _("album name"); ?><br />
@@ -51,7 +51,7 @@ $default_sort = "%a/%A";
</tr>
<tr>
<td><?php echo _("Path"); ?>: </td>
- <td><input size="60" type="text" name="path" value="<?php echo $_REQUEST['path']; ?>" size="30" /></td>
+ <td><input size="60" type="text" name="path" value="<?php echo $_REQUEST['path']; ?>" /></td>
</tr>
<tr>
<td><?php echo _("Catalog Type"); ?>: </td>
@@ -64,15 +64,15 @@ $default_sort = "%a/%A";
</tr>
<tr>
<td><?php echo _("ID3 Set Command"); ?>: </td>
- <td><input size="60" type="text" name="id3set_command" value="<?php echo $default_id3; ?>" size="30" /></td>
+ <td><input size="60" type="text" name="id3set_command" value="<?php echo $default_id3; ?>" /></td>
</tr>
<tr>
<td><?php echo _("Filename Pattern"); ?>: </td>
- <td><input size="60" type="text" name="rename_pattern" value="<?php echo $default_rename; ?>" size="30" /></td>
+ <td><input size="60" type="text" name="rename_pattern" value="<?php echo $default_rename; ?>" /></td>
</tr>
<tr>
<td><?php echo _("Folder Pattern"); ?>:<br /><?php echo _("(no leading or ending '/')"); ?></td>
- <td valign="top"><input size="60" type="text" name="sort_pattern" value="<?php echo $default_sort; ?>" size="30" /></td>
+ <td valign="top"><input size="60" type="text" name="sort_pattern" value="<?php echo $default_sort; ?>" /></td>
</tr>
<tr>
<td valign="top"><?php echo _("Gather Album Art"); ?>:</td>
diff --git a/templates/admin_menu.inc b/templates/admin_menu.inc
index 9b14f238..5d459bd8 100644
--- a/templates/admin_menu.inc
+++ b/templates/admin_menu.inc
@@ -30,11 +30,11 @@
$web_path = conf('web_path');
$items = array(
- _("Users") => "$web_path/admin/users.php",
- _("Mail Users") => "$web_path/admin/mail.php",
- _("Catalog") => "$web_path/admin/catalog.php",
- _("Admin Preferences") => "$web_path/admin/preferences.php",
- _("Access Lists") => "$web_path/admin/access.php"
+ "Users" => "$web_path/admin/users.php",
+ "Mail Users" => "$web_path/admin/mail.php",
+ "Catalog" => "$web_path/admin/catalog.php",
+ "Admin Preferences" => "$web_path/admin/preferences.php",
+ "Access Lists" => "$web_path/admin/access.php"
);
?>
@@ -43,10 +43,10 @@ $items = array(
<?php
foreach ( array_keys($items) as $item ) {
if ( $admin_highlight == $item ) {
- echo "<li class=\"active\"><a class=\"active\" href=\"$items[$item]\">$item</a></li>\n";
+ echo "<li class=\"active\"><a class=\"active\" href=\"$items[$item]\">" . _($item) . "</a></li>\n";
}
else {
- echo "<li><a href=\"$items[$item]\">$item</a></li>\n";
+ echo "<li><a href=\"$items[$item]\">" . _($item) . "</a></li>\n";
}
}
diff --git a/templates/header.inc b/templates/header.inc
index 04efb4fc..479a26d0 100644
--- a/templates/header.inc
+++ b/templates/header.inc
@@ -25,10 +25,10 @@ $htmllang = str_replace("_","-",conf('lang'));
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd">
-<html lang="<?php echo $htmllang; ?>">
+<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 conf('web_path'); ?>/favicon.ico" />
-<meta http-equiv="Content-Type" content="text/html; charset=<?php echo conf('site_charset'); ?>" />
+<meta http-equiv="Content-Style-Type" content="text/html" charset="<?php echo conf('site_charset'); ?>" />
<?php show_template('style'); ?>
<title><?php echo conf('site_title'); ?></title>
</head>
diff --git a/templates/javascript_refresh.inc b/templates/javascript_refresh.inc
index 2b04e46e..bd6be8ac 100644
--- a/templates/javascript_refresh.inc
+++ b/templates/javascript_refresh.inc
@@ -1,4 +1,4 @@
-<script language="JavaScript">
+<script language="JavaScript" type="text/javascript">
// Set refresh interval (in seconds)
var refreshinterval=<?= conf('refresh_limit'); ?>
diff --git a/templates/list_duplicates.inc b/templates/list_duplicates.inc
index d86df351..eef2eba0 100644
--- a/templates/list_duplicates.inc
+++ b/templates/list_duplicates.inc
@@ -60,10 +60,10 @@
foreach ($dinfolist as $dinfo)
{
echo "<tr class=\"".$class."\">".
- "<td><input type=\"checkbox\" name=\"song_ids[]\" value=\"" . $dinfo['songid'] . "\" />".
- "<td><a href=\"".conf('web_path')."/song.php?action=m3u&amp;song=$song->id\">$formated_title</td>".
- "<td><a href=\"".conf('web_path')."/artists.php?action=show&amp;artist=".$dinfo['artistid']."\" title=\"".$dinfo['artist']."\">".$dinfo['artist']."</a> </td>".
- "<td><a href=\"".conf('web_path')."/albums.php?action=show&amp;album=".$dinfo['albumid']."\" title=\"".$dinfo['album']."\">".$dinfo['album']."</a> </td>".
+ "<td><input type=\"checkbox\" name=\"song_ids[]\" value=\"" . $dinfo['songid'] . "\" /></td>".
+ "<td><a href=\"".conf('web_path')."/song.php?action=m3u&amp;song=$song->id\">".htmlspecialchars($formated_title)."</a> </td>".
+ "<td><a href=\"".conf('web_path')."/artists.php?action=show&amp;artist=".$dinfo['artistid']."\" title=\"".htmlspecialchars($dinfo['artist'])."\">".htmlspecialchars($dinfo['artist'])."</a> </td>".
+ "<td><a href=\"".conf('web_path')."/albums.php?action=show&amp;album=".$dinfo['albumid']."\" title=\"".htmlspecialchars($dinfo['album'])."\">".htmlspecialchars($dinfo['album'])."</a> </td>".
"<td>".floor($dinfo['time']/60).":".sprintf("%02d", ($dinfo['time']%60) )."</td>".
"<td>".intval($dinfo['bitrate']/1000)."</td>".
"<td>".sprintf("%.2f", ($dinfo['size']/1000000))."Mb</td>".
@@ -76,12 +76,11 @@
}
?>
<tr>
-<td colspan="8" class="<?php echo $class; ?>"><input height="15px" type="submit" value="Disable Songs" /></td>
+<td colspan="8" class="<?php echo $class; ?>"><input height="15" type="submit" value="Disable Songs" /></td>
</tr>
</table>
<?php } else { ?>
<p> You don't have any duplicate songs. </p>
-</form>
<?php } ?>
-
+</form>
diff --git a/templates/list_flagged.inc b/templates/list_flagged.inc
index 2a09e7e1..2207c9f0 100644
--- a/templates/list_flagged.inc
+++ b/templates/list_flagged.inc
@@ -35,7 +35,7 @@ this list to determine what songs you need to re-rip or tags you need to update.
<?php if ( $flags ) { ?>
<form name="songs" action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post">
-<table class="tabledata" cellspacing="0" cellpadding="0" border="1">
+<table class="tabledata" cellspacing="0" cellpadding="0" >
<tr class="table-header">
<td><a href="#" onclick="check_songs(); return false;">Select</a></td>
<td><?php echo _("Song"); ?></td>
diff --git a/templates/menu.inc b/templates/menu.inc
index ce5608f9..a6047ba5 100644
--- a/templates/menu.inc
+++ b/templates/menu.inc
@@ -48,7 +48,7 @@ if ($GLOBALS['user']->prefs['upload']) {
<ul id="mainmenu">
<?
foreach ( array_keys($items) as $item ) {
- if ( $high == $item ) {
+ if ( _($high) == $item ) {
print("\t\t<li class=\"active\"><a class=\"active\" href=\"$items[$item]\">$item</a></li>\n");
}
else {
@@ -86,4 +86,4 @@ if ($GLOBALS['user']->prefs['upload']) {
?>
</ul>
-<br /> \ No newline at end of file
+<br />
diff --git a/templates/show_artist.inc b/templates/show_artist.inc
index df0414a7..0653e97b 100644
--- a/templates/show_artist.inc
+++ b/templates/show_artist.inc
@@ -76,14 +76,13 @@ $artist_id = $artist->id;
<td><?php print $album->year; ?></td>
<td><?php print $count; ?></td>
<td>
- <a href="<?php print $web_path; ?>/song.php?action=m3u&amp;album=<?php print $id; ?>"><?php print _("Play"); ?></a>
- <?php if( batch_ok() ) { ?>
- | <a href="<?php echo conf('web_path'); ; ?>/batch.php?action=alb&amp;id=<?php echo $album->id; ?>"><?php echo _("Download"); ?></a>
- <?php } ?>
+ <a href="<?php print $web_path; ?>/song.php?action=m3u&amp;album=<?php print $id; ?>"><?php print _("Play"); ?></a>
+ <?php if( batch_ok() ) { ?>
+ | <a href="<?php echo conf('web_path'); ?>/batch.php?action=alb&amp;id=<?php echo $album->id; ?>"><?php echo _("Download"); ?></a>
+ <?php } ?>
</td>
-
-
- </td>
+
+
</tr>
<?php } ?>
</table>
diff --git a/templates/show_confirmation.inc.php b/templates/show_confirmation.inc.php
index 0268a081..d911a54b 100644
--- a/templates/show_confirmation.inc.php
+++ b/templates/show_confirmation.inc.php
@@ -27,7 +27,7 @@
<?php echo $text; ?>
</td></tr>
<tr><td>
- [ <a href="<?php echo $path; ?>"><?php echo _("Continue"); ?></a> ]
+ [ <a href="<?php echo htmlspecialchars($path); ?>"><?php echo _("Continue"); ?></a> ]
<br />
</td></tr>
</table>
diff --git a/templates/show_preferences.inc b/templates/show_preferences.inc
index b4a83176..079ff737 100644
--- a/templates/show_preferences.inc
+++ b/templates/show_preferences.inc
@@ -64,7 +64,7 @@
<tr>
<td><?php create_preference_input($pref->name,$pref->value); ?></td>
<?php if(preg_match('/Color/',$pref->description)) { ?>
- <td><table width="40" height="20" border="3" bgcolor="<?php echo $pref->value;?>"><tr><td></td></tr></table></td>
+ <td><table width="40" border="3" style="border-collapse: collapse;" bgcolor="<?php echo $pref->value;?>"><tr style="height:20px;"><td></td></tr></table></td>
<?php } else { ?>
<td></td>
<?php } ?>
diff --git a/templates/show_search.inc b/templates/show_search.inc
index 0e4d3532..26d202bc 100644
--- a/templates/show_search.inc
+++ b/templates/show_search.inc
@@ -29,7 +29,7 @@
?>
<form name="search" method="post" action="<?php echo conf('web_path'); ?>/search.php" enctype="multipart/form-data" style="Display:inline">
-<table class="tabledata" cellspacing="0" cellpadding="3" border="0" width="450px" style="clear:both;">
+<table class="tabledata" cellspacing="0" cellpadding="3" border="0" width="450" style="clear:both;">
<tr class="table-header">
<td colspan="2"><b><?php echo _("Search Ampache"); ?>...</b></td>
</tr>
diff --git a/templates/show_upload.inc b/templates/show_upload.inc
index 94ec45bc..88d2c2c8 100644
--- a/templates/show_upload.inc
+++ b/templates/show_upload.inc
@@ -1,7 +1,7 @@
<?php
/*
- Copyright (c) 2004 Ampache.org
+ Copyright (c) 2001 - 2005 Ampache.org
All rights reserved.
*Created by Lamar*
@@ -24,7 +24,7 @@
?>
<center>
<h3>
- <?php echo _("Please Ensure All Files Are Tagged Correctly"); ?>!!<br>
+ <?php echo _("Please Ensure All Files Are Tagged Correctly"); ?>!<br />
</h3>
<p>
<?php echo _("Ampache relies on id3 tags to sort data. If your file is not tagged it may be deleted."); ?>
@@ -35,49 +35,50 @@
<table class="tabledata" cellspacing="0" cellpadding="0" border="0" width="90%" align="center">
<tr align="center">
<td>
- <input size=40 type="file" name="ul_path1" id="ul_path1">
+ <input size=40 type="file" name="ul_path1" id="ul_path1" />
</td>
</tr>
<tr align="center">
<td>
- <input size=40 type="file" name="ul_path2" id="ul_path2">
+ <input size=40 type="file" name="ul_path2" id="ul_path2" />
</td>
</tr>
<tr align="center">
<td>
- <input size=40 type="file" name="ul_path3" id="ul_path3">
+ <input size=40 type="file" name="ul_path3" id="ul_path3" />
</td>
</tr>
<tr align="center">
<td>
- <input size=40 type="file" name="ul_path4" id="ul_path4">
+ <input size=40 type="file" name="ul_path4" id="ul_path4" />
</td>
</tr>
<tr align="center">
<td>
- <input type="hidden" name="action" value="upload_now">
- <input type="submit" value="<?php echo _("Upload"); ?>">
+ <input type="hidden" name="action" value="upload_now" />
+ <input type="submit" value="<?php echo _("Upload"); ?>" />
</td>
</tr>
</table>
</form>
-<p>
<table align="center" border = "0">
<tr>
<td>
- Acceptable formats include:
+ Acceptable formats include:
+ <ul>
<li>.mp3</li>
<li>.ogg</li>
<li>.wma</li>
<li>.flac</li>
+ </ul>
</td>
</tr>
</table>
-</p>
<!--
<p>
- Minimum Accepted Bitrate is <?= $site->prefs['upload_bitrate'] ?> kbps
+ <?php echo _("Minimum Accepted Bitrate is"); ?> <?php echo $site->prefs['upload_bitrate'] ?> kbps
</p>
-->
</center>
+
diff --git a/templates/tool_box.inc b/templates/tool_box.inc
index 36df59c4..fafdcfe8 100644
--- a/templates/tool_box.inc
+++ b/templates/tool_box.inc
@@ -35,7 +35,7 @@
<td class="even">
<?
foreach (array_keys($items) as $item) {
- print("\t\t\t>> <a href=\"$items[$item]\"> $item</a><br />\n");
+ print("\t\t\t&gt;&gt; <a href=\"$items[$item]\"> $item</a><br />\n");
}
?>
</td>
diff --git a/upload.php b/upload.php
index 493880a6..0c784473 100644
--- a/upload.php
+++ b/upload.php
@@ -145,7 +145,7 @@ switch ($action) {
} // end if known
// If unknown filetype
else{
- $message[$file['name']] .= "Error: Unsupported File Type- $ext<br>";
+ $message[$file['name']] .= "Error: Unsupported File Type- $ext<br />";
$errorenum[$file['name']]=true;
}
// foreach through files uploaded
@@ -224,7 +224,7 @@ if ( $handle = @opendir($user->prefs['upload_dir'] ) ){
} // end if upload_dir
?>
-<table class="tabledata" cellspacing="0" cellpadding="0" border="1" align="center">
+<table class="tabledata" cellspacing="0" cellpadding="0" align="center">
<tr class="table-header">
<td><?php echo _("Action"); ?></td>
<td><?php echo _("Song"); ?></td>
@@ -315,5 +315,9 @@ if ( $handle = @opendir($user->prefs['upload_dir'] ) ){
?>
-
</table>
+<br />
+<br />
+<br />
+<?php> show_page_footer ('Upload', '',$user->prefs['display_menu']); ?>
+