Changeset 1604 for branches/multiuser/tags.php
- Timestamp:
- 10/16/06 06:31:35 (2 years ago)
- Files:
-
- 1 modified
-
branches/multiuser/tags.php (modified) (9 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/multiuser/tags.php
r1502 r1604 36 36 $twhere .= "1=0"; 37 37 38 $sql = "select fid,tid,m.tdate from ".getTable('metatag') 39 ." m, ".getTable('tag')." t where m.tid=t.id and m.ttype = 'item'"40 ."and ($twhere)";38 $sql = "select fid,tid,m.tdate from ".getTable('metatag') . " m " 39 . "inner join " . getTable('tag')." t on m.tid=t.id " 40 . "where m.ttype = 'item' and ($twhere)"; 41 41 42 42 //echo $sql; … … 54 54 if (count($fids)) { 55 55 $sql = "select t.tag, count(*) as cnt from ".getTable('metatag') 56 ." m left join ".getTable('item')." i on (m.fid=i.id) ,"57 . getTable('tag')." t"58 ." where m. tid=t.id and m.fid in (".implode(",", $fids).")"56 ." m left join ".getTable('item')." i on (m.fid=i.id) " 57 ." inner join " . getTable('tag')." t on (m.tid=t.id)" 58 ." where m.fid in (".implode(",", $fids).")" 59 59 ." and t.id not in (".implode(",", $tids).")"; 60 60 … … 79 79 $twhere = ""; 80 80 $tarr = explode(" ", $tag); 81 $hrTag = implode(" ". LBL_AND." ", $tarr);81 $hrTag = implode(" ".__('and')." ", $tarr); 82 82 $urlTag = implode("+", $tarr); 83 83 … … 87 87 $twhere .= " 1=0"; 88 88 89 $sql = "select fid, count(*) as cnt from " 90 .getTable('metatag')." m, " 91 .getTable('tag')." t " 92 ." where m.tid=t.id and ($twhere) " 93 ." and m.ttype = 'item'" 89 $sql = "select fid, count(*) as cnt from ".getTable('metatag')." m " 90 ."inner join " . getTable('tag')." t on m.tid=t.id " 91 ." where ($twhere) and m.ttype = 'item'" 94 92 ." group by fid order by 2 desc"; 95 93 … … 116 114 $relPlus = array_key_exists($rtag, $taggedItems->allTags); 117 115 if ($relPlus) { 118 $relLbl .= " [<a "."title=\"$cnt ". ($cnt > 1 ? LBL_ITEMS : LBL_ITEM)." ". ($cnt > 1 || $cnt == 0 ? LBL_TAG_TAGGEDP : LBL_TAG_TAGGED)." '".$hrTag." ".LBL_AND." $rtag'\" "."href=\"".getPath()."". (getConfig('rss.output.usemodrewrite') ? "tag/$rtag" : "tags.php?tag=$rtag").""."+".$urlTag."\">+</a>]";116 $relLbl .= " [<a "."title=\"$cnt ". ($cnt > 1 ? __('items') : __('item'))." ". ($cnt > 1 || $cnt == 0 ? __('tagged') : __('tagged'))." '".$hrTag." ".__('and')." $rtag'\" "."href=\"".getPath()."". (getConfig('rss.output.usemodrewrite') ? "tag/$rtag" : "tags.php?tag=$rtag").""."+".$urlTag."\">+</a>]"; 119 117 } 120 118 $idx = ($relPlus ? $taggedItems->allTags[$rtag] : 0); … … 128 126 rss_require('cls/rdf.php'); 129 127 // RSS view 130 $title = _TITLE_." - ". LBL_TAG_TAGS." - ".$hrTag;128 $title = _TITLE_." - ".__('Tags')." - ".$hrTag; 131 129 $baselink = guessTransportProto().$_SERVER['HTTP_HOST'].getPath() 132 130 . (getConfig('rss.output.usemodrewrite') ? "tag/" : "tags.php?tag="); … … 151 149 if ($gotsome) { 152 150 153 $title = $taggedItems->itemCount." ". ($taggedItems->itemCount > 1 ? LBL_ITEMS : LBL_ITEM)." "154 . ($taggedItems->itemCount > 1 || $taggedItems->itemCount == 0 ? LBL_TAG_TAGGEDP : LBL_TAG_TAGGED)151 $title = $taggedItems->itemCount." ". ($taggedItems->itemCount > 1 ? __('items') : __('item'))." " 152 . ($taggedItems->itemCount > 1 || $taggedItems->itemCount == 0 ? __('tagged') : __('tagged')) 155 153 .""." \"".$hrTag."\""; 156 154 157 155 if (count($related)) { 158 $taggedItems->beforeList = "\n<p>". LBL_TAG_RELATED."\n".implode(", \n", $related)."\n</p>\n";156 $taggedItems->beforeList = "\n<p>".__('Related tags: ')."\n".implode(", \n", $related)."\n</p>\n"; 159 157 } 160 158 … … 167 165 } else { 168 166 echo "<p style=\"height: 10em; text-align:center\">"; 169 printf( LBL_TAG_ERROR_NO_TAG, $hrTag);167 printf(__('Oops! No items tagged «%s» were found.'), $hrTag); 170 168 echo "</p>"; 171 169 } … … 177 175 rss_require('cls/alltags.php'); 178 176 179 $GLOBALS['rss']->header = new Header("Tags ".TITLE_SEP." ". LBL_TAG_ALL_TAGS);177 $GLOBALS['rss']->header = new Header("Tags ".TITLE_SEP." ".__('All Tags')); 180 178 $GLOBALS['rss']->feedList = new FeedList(false); 181 179 $allTags = new Tags();
