diff options
Diffstat (limited to 'data/templates/bookmarks.tpl.php')
-rw-r--r-- | data/templates/bookmarks.tpl.php | 31 |
1 files changed, 17 insertions, 14 deletions
diff --git a/data/templates/bookmarks.tpl.php b/data/templates/bookmarks.tpl.php index c404358..55d6a0f 100644 --- a/data/templates/bookmarks.tpl.php +++ b/data/templates/bookmarks.tpl.php @@ -62,12 +62,16 @@ if($currenttag!= '' && $cdservice->getLastTagDescription($currenttag)) { } //common tag description edit -if($userservice->isLoggedOn()) { - if($currenttag!= '' && ($GLOBALS['enableCommonTagDescriptionEditedByAll'] || $currentUser->isAdmin())) { +if ($userservice->isLoggedOn()) { + if ($currenttag != '' + && ($GLOBALS['enableCommonTagDescriptionEditedByAll'] + || $currentUser->isAdmin() + ) + ) { echo ' <a href="'. createURL('tagcommondescriptionedit', $currenttag).'" title="'.T_('Edit the common description of this tag').'">'; echo !is_array($cDescription) || strlen($cDescription['cdDescription'])==0?T_('Edit the common description of this tag'):''; echo ' <img src="'.ROOT.'images/b_edit.png" /></a>'; - } elseif(isset($hash)) { + } else if (isset($hash)) { echo ' (<a href="'.createURL('bookmarkcommondescriptionedit', $hash).'" title="'.T_('Edit the common description of this bookmark').'">'; echo T_('Edit the common description of this bookmark').'</a>)'; } @@ -117,33 +121,33 @@ $votingSort = 'voting_desc'; switch(getSortOrder()) { case 'date_asc': - $dateArrow = ' ↑'; + $dateArrow = ' ↑'; $dateSort = 'date_desc'; break; case 'title_asc': - $titleArrow = ' ↑'; + $titleArrow = ' ↑'; $titleSort = 'title_desc'; break; case 'title_desc': - $titleArrow = ' ↓'; + $titleArrow = ' ↓'; $titleSort = 'title_asc'; break; case 'voting_asc': - $votingArrow = ' ↑'; + $votingArrow = ' ↑'; $votingSort = 'voting_desc'; break; case 'voting_desc': - $votingArrow = ' ↓'; + $votingArrow = ' ↓'; $votingSort = 'voting_asc'; break; case 'date_desc': default: - $dateArrow = ' ↓'; + $dateArrow = ' ↓'; $dateSort = 'date_asc'; break; } @@ -292,10 +296,9 @@ if ($currenttag!= '') { $edit = ' - <a href="' . createURL('edit', $row['bId']) . '">' . T_('Edit') . '</a>' - . '<script type="text/javascript">' - . 'document.write(" - <a href=\"#\" onclick=\"deleteBookmark(this, '. $row['bId'] .'); return false;\">' + . ' <a href="#" onclick="deleteBookmark(this, '. $row['bId'] .'); return false;">' . T_('Delete') - .'<\/a>");</script>'; + .'</a>'; } // Last update @@ -313,7 +316,7 @@ if ($currenttag!= '') { . '</a>'; } - // Udders! + // others if (!isset($hash)) { $others = $otherCounts[$row['bAddress']]; $ostart = '<a href="' . createURL('history', $row['bHash']) . '">'; @@ -391,7 +394,7 @@ if ($currenttag!= '') { echo ' <div' . $adminBgClass . '>' . "\n"; echo ' <div class="link">' - . '<a href="'. $address .'"'. $rel .' class="taggedlink" target="_blank">' + . '<a href="'. htmlspecialchars($address) .'"'. $rel .' class="taggedlink">' . filter($row['bTitle']) . '</a>' . $adminStar . "</div>\n"; if ($row['bDescription'] == '') { |