diff options
Diffstat (limited to 'templates')
-rw-r--r-- | templates/add_catalog.inc | 3 | ||||
-rw-r--r-- | templates/admin_menu.inc | 55 | ||||
-rw-r--r-- | templates/catalog.inc | 15 | ||||
-rw-r--r-- | templates/customize_catalog.inc | 8 | ||||
-rw-r--r-- | templates/header.inc | 2 | ||||
-rw-r--r-- | templates/list_duplicates.inc | 42 |
6 files changed, 29 insertions, 96 deletions
diff --git a/templates/add_catalog.inc b/templates/add_catalog.inc index f0493269..5d156d99 100644 --- a/templates/add_catalog.inc +++ b/templates/add_catalog.inc @@ -1,7 +1,7 @@ <?php /* - Copyright (c) 2001 - 2005 Ampache.org + Copyright (c) 2001 - 2006 Ampache.org All rights reserved. This program is free software; you can redistribute it and/or @@ -19,6 +19,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ + $default_id3 = "/usr/bin/id3v2 -a "%a" -A "%A" -t "%t" -g %g -y %y -T %T -c "%c" %filename"; $default_rename = "%a - %T - %t"; $default_sort = "%a/%A"; diff --git a/templates/admin_menu.inc b/templates/admin_menu.inc deleted file mode 100644 index f87d85eb..00000000 --- a/templates/admin_menu.inc +++ /dev/null @@ -1,55 +0,0 @@ -<?php -/* - - Copyright (c) 2001 - 2005 Ampache.org - All rights reserved. - - This program is free software; you can redistribute it and/or - modify it under the terms of the GNU General Public License - as published by the Free Software Foundation; either version 2 - of the License, or (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - -*/ - -/* - - @header - A template file - -*/ - -$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" - ); - -?> -<ul id="adminmenu"> - - <?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"; - } - else { - echo "<li><a href=\"$items[$item]\">" . $item . "</a></li>\n"; - } - } - - ?> -</ul> -<br /> diff --git a/templates/catalog.inc b/templates/catalog.inc index 79030725..ab2fb3f3 100644 --- a/templates/catalog.inc +++ b/templates/catalog.inc @@ -1,7 +1,7 @@ <?php /* - Copyright (c) 2001 - 2005 Ampache.org + Copyright (c) 2001 - 2006 Ampache.org All rights reserved. This program is free software; you can redistribute it and/or @@ -19,15 +19,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* - - @header - A template file - -*/ - +/** + * Catalog Display + * This template displays all of the catalogs... Currently it's a little cluttered + * It would be great if someone cleaned this up + */ ?> - <br /> <?php if (!function_exists('iconv')) { ?> <div class="fatalerror"><?php echo _("Error: ICONV not found, ID3V2 Tags will not import correctly. See <a href=\"http://php.oregonstate.edu/iconv\">Iconv</a> for information on getting ICONV"); ?></div> diff --git a/templates/customize_catalog.inc b/templates/customize_catalog.inc index 464149ad..a0813036 100644 --- a/templates/customize_catalog.inc +++ b/templates/customize_catalog.inc @@ -1,7 +1,7 @@ <?php /* - Copyright (c) 2001 - 2005 Ampache.org + Copyright (c) 2001 - 2006 Ampache.org All rights reserved. This program is free software; you can redistribute it and/or @@ -44,13 +44,13 @@ <tr> <td><?php echo _("ID3 set command"); ?>:</td> <td> - <input size="60" type="text" name="id3_set_command" value="<?php echo htmlspecialchars($catalog->id3_set_command); ?>" /> + <input size="60" type="text" name="id3_set_command" value="<?php echo scrub_out($catalog->id3_set_command); ?>" /> </td> </tr> <tr> <td><?php echo _("Filename pattern"); ?>:</td> <td> - <input size="60" type="text" name="rename_pattern" value="<?php echo htmlspecialchars($catalog->rename_pattern); ?>" /> + <input size="60" type="text" name="rename_pattern" value="<?php echo scrub_out($catalog->rename_pattern); ?>" /> </td> </tr> <tr> @@ -58,7 +58,7 @@ <?php echo _("Folder Pattern"); ?>:<br /><?php echo _("(no leading or ending '/')"); ?> </td> <td> - <input size="60" type="text" name="sort_pattern" value="<?php echo htmlspecialchars($catalog->sort_pattern);?>" /> + <input size="60" type="text" name="sort_pattern" value="<?php echo scrub_out($catalog->sort_pattern);?>" /> </td> </tr> <tr> diff --git a/templates/header.inc b/templates/header.inc index d69cee63..91700508 100644 --- a/templates/header.inc +++ b/templates/header.inc @@ -1,7 +1,7 @@ <?php /* - Copyright (c) 2001 - 2005 Ampache.org + Copyright (c) 2001 - 2006 Ampache.org All rights reserved. This program is free software; you can redistribute it and/or diff --git a/templates/list_duplicates.inc b/templates/list_duplicates.inc index eef2eba0..8bf052dc 100644 --- a/templates/list_duplicates.inc +++ b/templates/list_duplicates.inc @@ -1,7 +1,7 @@ <?php /* - Copyright (c) 2001 - 2005 Ampache.org + Copyright (c) 2001 - 2006 Ampache.org All rights reserved. This program is free software; you can redistribute it and/or @@ -19,37 +19,28 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ - - -/*! - @header - A template file for listing duplicate songs - -*/ ?> <?php show_duplicate_searchbox($search_type) ?> <?php if ( $flags ) { ?> <form method="post" enctype="multipart/form-data" action="<?php echo conf('web_path') . "/admin/song.php?action=disable"; ?>"> -<p style="font-size: 10pt; font-weight: bold;">Duplicate Songs</p> +<p class="header1"><?php echo _('Duplicate Songs'); ?></p> <table class="tabledata" cellspacing="0" cellpadding="0" > <tr class="table-header"> - <td>Disable</td> - <td>Song</td> - <td>Artist</td> - <td>Album</td> - <td>Length</td> - <td>Bitrate</td> - <td>Size</td> - <td>Filename</td> + <td><?php echo _('Disable'); ?></td> + <td><?php echo _('Song'); ?></td> + <td><?php echo _('Artist'); ?></td> + <td><?php echo _('Album'); ?></td> + <td><?php echo _('Length'); ?></td> + <td><?php echo _('Bitrate'); ?></td> + <td><?php echo _('Size'); ?></td> + <td><?php echo _('Filename'); ?></td> </tr> <?php - $class="odd"; foreach ($flags as $flag) { $song = new Song($flag['song']); $song->format_song(); - $class = (++$i%2)?'odd':'even'; $alt_title = $song->title; $formated_title = $song->f_title; @@ -59,11 +50,11 @@ $dinfolist = get_duplicate_info($song,$search_type); foreach ($dinfolist as $dinfo) { - echo "<tr class=\"".$class."\">". + echo "<tr class=\"".flip_class()."\">". "<td><input type=\"checkbox\" name=\"song_ids[]\" value=\"" . $dinfo['songid'] . "\" /></td>". - "<td><a href=\"".conf('web_path')."/song.php?action=m3u&song=$song->id\">".htmlspecialchars($formated_title)."</a> </td>". - "<td><a href=\"".conf('web_path')."/artists.php?action=show&artist=".$dinfo['artistid']."\" title=\"".htmlspecialchars($dinfo['artist'])."\">".htmlspecialchars($dinfo['artist'])."</a> </td>". - "<td><a href=\"".conf('web_path')."/albums.php?action=show&album=".$dinfo['albumid']."\" title=\"".htmlspecialchars($dinfo['album'])."\">".htmlspecialchars($dinfo['album'])."</a> </td>". + "<td><a href=\"".conf('web_path')."/song.php?action=m3u&song=$song->id\">".scrub_out($formated_title)."</a> </td>". + "<td><a href=\"".conf('web_path')."/artists.php?action=show&artist=".$dinfo['artistid']."\" title=\"".scrub_out($dinfo['artist'])."\">".scrub_out($dinfo['artist'])."</a> </td>". + "<td><a href=\"".conf('web_path')."/albums.php?action=show&album=".$dinfo['albumid']."\" title=\"".scrub_out($dinfo['album'])."\">".scrub_out($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,11 +67,10 @@ } ?> <tr> -<td colspan="8" class="<?php echo $class; ?>"><input height="15" type="submit" value="Disable Songs" /></td> +<td colspan="8" class="<?php echo flip_class(); ?>"><input height="15" type="submit" value="Disable Songs" /></td> </tr> </table> <?php } else { ?> - -<p> You don't have any duplicate songs. </p> +<p><?php _('You don't have any duplicate songs.'); ?></p> <?php } ?> </form> |