summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorKarl 'vollmerk' Vollmer <vollmer@ampache.org>2006-03-23 09:01:04 +0000
committerKarl 'vollmerk' Vollmer <vollmer@ampache.org>2006-03-23 09:01:04 +0000
commit80b0748b4a43087aed6802b6b631f064f975f097 (patch)
tree045d64e4538693edbd20362085ce506758e7221c /templates
parent78164aefef355b07df4b28f913f38fc0b0473508 (diff)
downloadampache-80b0748b4a43087aed6802b6b631f064f975f097.tar.gz
ampache-80b0748b4a43087aed6802b6b631f064f975f097.tar.bz2
ampache-80b0748b4a43087aed6802b6b631f064f975f097.zip
fixed playlist name editing so confirmation box works, and its a little snazzier now
Diffstat (limited to 'templates')
-rw-r--r--templates/show_playlist_box.inc.php7
-rw-r--r--templates/show_playlist_edit.inc.php51
-rw-r--r--templates/show_playlists.inc.php18
3 files changed, 61 insertions, 15 deletions
diff --git a/templates/show_playlist_box.inc.php b/templates/show_playlist_box.inc.php
index 6e595743..98f5b680 100644
--- a/templates/show_playlist_box.inc.php
+++ b/templates/show_playlist_box.inc.php
@@ -34,14 +34,15 @@ $playlist_id = scrub_out($_REQUEST['playlist_id']);
<td>
<span class="header1"><?php echo _('Playlist Actions'); ?></span><br />
<ul class="text-action">
- <li><a href="<?php echo $web_path; ?>/playlist.php?action=new"><?php echo _('Create New Playlist'); ?></a></li>
- <li><a href="<?php echo $web_path; ?>/playlist.php"><?php echo _('View All Playlists'); ?></a></li>
- <li><a href="<?php echo $web_path; ?>/playlist.php?action=show_import_playlist"><?php echo _('Import From File'); ?></a></li>
<?php if ($_REQUEST['playlist_id']) { ?>
+ <li><a href="<?php echo $web_path; ?>/playlist.php?action=edit&amp;playlist_id=<?php echo $playlist_id; ?>"><?php echo _('Edit Playlist'); ?></a></li>
<li><a href="<?php echo $web_path; ?>/playlist.php?action=normalize_tracks&amp;playlist_id=<?php echo $playlist_id; ?>"><?php echo _('Normalize Tracks'); ?></a></li>
<li><a href="<?php echo $web_path; ?>/song.php?action=play_selected&amp;playlist_id=<?php echo $playlist_id; ?>"><?php echo _('Play This Playlist'); ?></a></li>
<li><a href="<?php echo $web_path; ?>/playlist.php?action=show_delete_playlist&amp;playlist_id=<?php echo $playlist_id; ?>"><?php echo _('Delete This Playlist'); ?></a></li>
<?php } ?>
+ <li><a href="<?php echo $web_path; ?>/playlist.php?action=new"><?php echo _('Create New Playlist'); ?></a></li>
+ <li><a href="<?php echo $web_path; ?>/playlist.php"><?php echo _('View All Playlists'); ?></a></li>
+ <li><a href="<?php echo $web_path; ?>/playlist.php?action=show_import_playlist"><?php echo _('Import From File'); ?></a></li>
</ul>
</td>
</tr>
diff --git a/templates/show_playlist_edit.inc.php b/templates/show_playlist_edit.inc.php
new file mode 100644
index 00000000..afb12056
--- /dev/null
+++ b/templates/show_playlist_edit.inc.php
@@ -0,0 +1,51 @@
+<?php
+/*
+
+ Copyright (c) 2001 - 2006 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.
+
+*/
+?>
+<form method="post" action="<?php echo $web_path; ?>/playlist.php" enctype="multipart/form-data">
+<table class="text-box">
+<tr>
+ <td colspan="2" class="header2"><?php echo _('Editing Playlist'); ?></td>
+</tr>
+<tr>
+ <td><?php echo _('Name'); ?>:</td>
+ <td align="left">
+ <input type="text" name="playlist_name" value="<?php echo scrub_out($playlist->name); ?>" size="<?php echo strlen($playlist->name)+3; ?>" />
+ </td>
+</tr>
+<tr>
+ <td valign="top"><?php echo _('Type'); ?>:</td>
+ <td>
+ <?php $select_name = 'selected_' . $playlist->type; ${$select_name} = "checked=\"checked\""; ?>
+ <input type="radio" name="type" value="public" <?php echo $selected_public; ?>/><?php echo _('Public'); ?><br />
+ <input type="radio" name="type" value="private" <?php echo $selected_private; ?>/><?php echo _('Private'); ?><br />
+ </td>
+</tr>
+<tr>
+ <td>&nbsp;</td>
+ <td>
+ <input type="hidden" name="playlist_id" value="<?php echo $playlist->id; ?>" />
+ <input type="hidden" name="action" value="update_playlist" />
+ <input type="submit" value="<?php echo _('Update'); ?>" />
+ </td>
+</tr>
+</table>
+</form>
diff --git a/templates/show_playlists.inc.php b/templates/show_playlists.inc.php
index c8feb382..a18cb651 100644
--- a/templates/show_playlists.inc.php
+++ b/templates/show_playlists.inc.php
@@ -49,27 +49,21 @@ foreach ($playlists as $playlist) {
<td><?php echo scrub_out($playlist_user->fullname); ?></td>
<td>
| <a href="<?php echo $web_path; ?>/playlist.php?action=show_playlist&amp;playlist_id=<?php echo $playlist->id; ?>">
- <?php echo _('View'); ?>
- </a>
+ <?php echo _('View'); ?></a>
<?php if (($GLOBALS['user']->username == $playlist->user) || ($GLOBALS['user']->has_access(100))) { ?>
| <a href="<?php echo $web_path; ?>/playlist.php?action=edit&amp;playlist_id=<?php echo $playlist->id; ?>">
- <?php echo _('Edit'); ?>
- </a>
+ <?php echo _('Edit'); ?></a>
| <a href="<?php echo $web_path; ?>/playlist.php?action=show_delete_playlist&amp;playlist_id=<?php echo $playlist->id; ?>">
- <?php echo _('Delete'); ?>
- </a>
+ <?php echo _('Delete'); ?></a>
<?php } ?>
<?php if ($count > 0) { ?>
| <a href="<?php echo $web_path; ?>/song.php?action=playlist&amp;playlist_id=<?php echo $playlist->id; ?>">
- <?php echo _('Play'); ?>
- </a>
+ <?php echo _('Play'); ?></a>
| <a href="<?php echo $web_path; ?>/song.php?action=playlist_random&amp;playlist_id=<?php echo $playlist->id; ?>">
- <?php echo _('Random'); ?>
- </a>
+ <?php echo _('Random'); ?></a>
<?php if (batch_ok()) { ?>
| <a href="<?php echo $web_path; ?>/batch.php?action=pl&amp;id=<?php echo $playlist->id; ?>">
- <?php echo _('Download'); ?>
- </a>
+ <?php echo _('Download'); ?></a>
<?php } ?>
<?php } ?>
|