]> projects.mako.cc - scuttle/blob - templates/sidebar.block.tagactions.php
removed code for string overloading
[scuttle] / templates / sidebar.block.tagactions.php
1 <?php
2 $sf = new ServiceFactory();
3 $userservice =& $sf->getServiceInstance('UserService');
4 if ($userservice->isLoggedOn()) {
5     $currentUser = $userservice->getCurrentUser();
6     $currentUsername = $currentUser[$userservice->getFieldName('username')];
7
8     if ($currentUsername == $user) {
9         $tags = explode('+', $currenttag);
10         $renametext = T_ngettext('Rename Tag', 'Rename Tags', count($tags));
11         $renamelink = createURL('tagrename', $currenttag);
12         $deletelink = createURL('tagdelete', $currenttag);
13 ?>
14
15 <h2><?php echo T_('Actions'); ?></h2>
16 <div id="tagactions">
17     <ul>
18         <li><a href="<?php echo $renamelink; ?>"><?php echo $renametext ?></a></li>
19         <?php if (count($tags) == 1): ?>
20         <li><a href="<?php echo $deletelink; ?>"><?php echo T_('Delete Tag') ?></a></li>
21         <?php endif; ?>
22     </ul>
23 </div>
24
25 <?php
26     }
27 }
28 ?>

Benjamin Mako Hill || Want to submit a patch?