Changeset 1561 for trunk/gregarius/cls
- Timestamp:
- 09/09/06 14:52:23 (2 years ago)
- Location:
- trunk/gregarius/cls
- Files:
-
- 13 modified
-
categories.php (modified) (2 diffs)
-
channels.php (modified) (3 diffs)
-
header.php (modified) (2 diffs)
-
items.php (modified) (2 diffs)
-
nav.php (modified) (1 diff)
-
search.php (modified) (1 diff)
-
taglist.php (modified) (2 diffs)
-
update.php (modified) (7 diffs)
-
wrappers/feeds.php (modified) (2 diffs)
-
wrappers/header.php (modified) (2 diffs)
-
wrappers/item.php (modified) (3 diffs)
-
wrappers/searchform.php (modified) (3 diffs)
-
wrappers/toolkit.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/gregarius/cls/categories.php
r1549 r1561 58 58 $this->loadCollapsedState(); 59 59 $this -> populate(); 60 $this -> columnTitle = LBL_TAG_FOLDERS;60 $this -> columnTitle = __('Categories'); 61 61 $GLOBALS['rss']-> feedList = $this; 62 62 } … … 85 85 86 86 function getStats() { 87 return sprintf( LBL_CATCNT_PF, $this -> taggedFeedCnt, $this -> tagCnt, 0);87 return sprintf(__('<strong>%d</strong> feeds in <strong>%d</strong> categories'), $this -> taggedFeedCnt, $this -> tagCnt, 0); 88 88 } 89 89 -
trunk/gregarius/cls/channels.php
r1544 r1561 97 97 98 98 if ($unreadCount > 0) { 99 $this->rdLbl= sprintf( LBL_UNREAD_PF, "cid$id","",$unreadCount);99 $this->rdLbl= sprintf(__('<strong id="%s" style="%s">(%d unread)</strong>'), "cid$id","",$unreadCount); 100 100 $this->class_= "feed title unread"; 101 101 } else { … … 151 151 var $activeId; 152 152 var $feedCount = 0; 153 var $columnTitle = LBL_H2_CHANNELS;153 var $columnTitle; 154 154 var $stats; 155 155 156 156 function FeedList($activeId) { 157 157 _pf('FeedList() ctor'); 158 $this ->columnTitle= __('Feeds'); 158 159 $this->activeId = $activeId; 159 160 $this->loadCollapsedState(); … … 191 192 _pf(' ... done: feedsCount'); 192 193 193 $this ->stats = sprintf( LBL_ITEMCOUNT_PF, $total, $unread, $channelcount);194 $this ->stats = sprintf(__('<strong>%d</strong> items (<strong id="fucnt">%d</strong> unread) in <strong>%d</strong> feeds'), $total, $unread, $channelcount); 194 195 _pf('done: getStats()'); 195 196 return $this -> stats; -
trunk/gregarius/cls/header.php
r1181 r1561 60 60 is_array($cidfid) && 61 61 ($uc = getUnreadCount($cidfid['cid'], $cidfid['fid']))) { 62 $this->docTitle .= " ($uc ". LBL_UNREAD.")";62 $this->docTitle .= " ($uc ".__('unread').")"; 63 63 } 64 64 … … 95 95 96 96 $GLOBALS['rss'] -> sideMenu = new SideMenu(); 97 $GLOBALS['rss'] -> sideMenu -> addMenu( LBL_H2_CHANNELS,'FeedList' , "_side('FeedList')");98 $GLOBALS['rss'] -> sideMenu -> addMenu( LBL_TAG_FOLDERS, 'CatList', "_side('CatList')");99 $GLOBALS['rss'] -> sideMenu -> addMenu( LBL_TAG_TAGS, 'TagList', "_side('TagList')");97 $GLOBALS['rss'] -> sideMenu -> addMenu(__('Feeds'),'FeedList' , "_side('FeedList')"); 98 $GLOBALS['rss'] -> sideMenu -> addMenu(__('Categories'), 'CatList', "_side('CatList')"); 99 $GLOBALS['rss'] -> sideMenu -> addMenu(__('Tags'), 'TagList', "_side('TagList')"); 100 100 } 101 101 -
trunk/gregarius/cls/items.php
r1543 r1561 485 485 var $_parent; 486 486 var $pages; 487 function ItemListNavigation( $il) {487 function ItemListNavigation(&$il) { 488 488 $this -> _parent = $il; 489 489 $this -> pages = array(); … … 535 535 . $this -> _sqlActualWhere; 536 536 list($this -> numItems) = rss_fetch_row(rss_query($sql)); 537 $this -> navigation = new ItemListNavigation( &$this);537 $this -> navigation = new ItemListNavigation($this); 538 538 } 539 539 } -
trunk/gregarius/cls/nav.php
r1347 r1561 60 60 function Navigation() { 61 61 62 $this->appendNavItem(getPath(), LBL_NAV_HOME,LOCATION_HOME);63 $this->appendNavItem(getPath().'update.php', LBL_NAV_UPDATE,LOCATION_UPDATE);64 $this->appendNavItem(getPath().'search.php', LBL_NAV_SEARCH,LOCATION_SEARCH);65 $this->appendNavItem(getPath().'admin/', LBL_NAV_CHANNEL_ADMIN,LOCATION_ADMIN);62 $this->appendNavItem(getPath(),__('<span>H</span>ome'),LOCATION_HOME); 63 $this->appendNavItem(getPath().'update.php',__('<span>R</span>efresh'),LOCATION_UPDATE); 64 $this->appendNavItem(getPath().'search.php',__('<span>S</span>earch'),LOCATION_SEARCH); 65 $this->appendNavItem(getPath().'admin/',__('A<span>d</span>min'),LOCATION_ADMIN); 66 66 67 67 if (($an = rss_plugin_hook('rss.plugins.afternav', null)) != null) { -
trunk/gregarius/cls/search.php
r1528 r1561 211 211 if ($this->resultsPerPage != INFINE_RESULTS && $this->itemCount > $this->resultsPerPage) { 212 212 $nav .= "<div class=\"readmore\">"; 213 $nav .= LBL_SEARCH_RESULTS;213 $nav .= __('Results: '); 214 214 215 215 // first page -
trunk/gregarius/cls/taglist.php
r1181 r1561 67 67 function TagList() { 68 68 $this -> populate(); 69 $this -> columnTitle = LBL_TAG_TAGS;69 $this -> columnTitle = __('Tags'); 70 70 $GLOBALS['rss']-> feedList = $this; 71 71 } … … 84 84 85 85 function getStats() { 86 return sprintf( LBL_TAGCOUNT_PF, $this -> countTaggedItems, $this->tagCount);86 return sprintf(__('<strong>%d</strong> tagged items, in <strong>%d</strong> tags'), $this -> countTaggedItems, $this->tagCount); 87 87 } 88 88 -
trunk/gregarius/cls/update.php
r1544 r1561 116 116 if ($error & MAGPIE_FEED_ORIGIN_CACHE) { 117 117 if ($error & MAGPIE_FEED_ORIGIN_HTTP_304) { 118 $label = LBL_UPDATE_NOT_MODIFIED;118 $label = __('OK (304 Not modified)'); 119 119 $cls = ERROR_NOERROR; 120 120 } 121 121 elseif ($error & MAGPIE_FEED_ORIGIN_HTTP_TIMEOUT) { 122 $label = LBL_UPDATE_CACHE_TIMEOUT;122 $label = __('HTTP Timeout (Local cache)'); 123 123 $cls = ERROR_WARNING; 124 124 } 125 125 elseif ($error & MAGPIE_FEED_ORIGIN_NOT_FETCHED) { 126 $label = LBL_UPDATE_STATUS_CACHED;126 $label = __('OK (Local cache)'); 127 127 $cls = ERROR_NOERROR; 128 128 } 129 129 elseif ($error & MAGPIE_FEED_ORIGIN_HTTP_404) { 130 $label = LBL_UPDATE_NOT_FOUND;130 $label = __('404 Not Found (Local cache)'); 131 131 $cls = ERROR_ERROR; 132 132 } … … 137 137 } 138 138 elseif ($error & MAGPIE_FEED_ORIGIN_HTTP_200) { 139 $label = LBL_UPDATE_STATUS_OK;139 $label = __('OK (HTTP 200)'); 140 140 $cls = ERROR_NOERROR; 141 141 } 142 142 else { 143 143 if (is_numeric($error)) { 144 $label = LBL_UPDATE_STATUS_ERROR;144 $label = __('ERROR'); 145 145 $cls = ERROR_ERROR; 146 146 } else { … … 177 177 178 178 echo 179 "<h2>".sprintf( LBL_UPDATE_H2, count($this -> chans))."</h2>\n"179 "<h2>".sprintf(__('Updating %d Feeds...'), count($this -> chans))."</h2>\n" 180 180 ."<table id=\"updatetable\">\n" 181 181 ."<tr>\n" 182 ."<th class=\"lc\">". LBL_UPDATE_CHANNEL."</th>\n"183 ."<th class=\"mc\">". LBL_UPDATE_STATUS."</th>\n"184 ."<th class=\"rc\">". LBL_UPDATE_UNREAD."</th>\n"182 ."<th class=\"lc\">".__('Feed')."</th>\n" 183 ."<th class=\"mc\">".__('Status')."</th>\n" 184 ."<th class=\"rc\">".__('New Items')."</th>\n" 185 185 ."</tr>"; 186 186 … … 239 239 function render() { 240 240 241 echo "<h2 style=\"margin-bottom:1em;\">". sprintf( LBL_UPDATE_H2,count($this -> chans)) ."</h2>\n";241 echo "<h2 style=\"margin-bottom:1em;\">". sprintf(__('Updating %d Feeds...'),count($this -> chans)) ."</h2>\n"; 242 242 243 243 echo "<table id=\"updatetable\">\n" 244 244 ."<tr>\n" 245 ."<th class=\"lc\">". LBL_UPDATE_CHANNEL."</th>\n"246 ."<th class=\"mc\">". LBL_UPDATE_STATUS."</th>\n"247 ."<th class=\"rc\">". LBL_UPDATE_UNREAD."</th>\n"245 ."<th class=\"lc\">".__('Feed')."</th>\n" 246 ."<th class=\"mc\">".__('Status')."</th>\n" 247 ."<th class=\"rc\">".__('New Items')."</th>\n" 248 248 ."</tr>\n"; 249 249 … … 296 296 297 297 list($label,$cls) = parent::magpieError($error); 298 echo "\n$label, $unread " . LBL_UPDATE_UNREAD. "\n\n";298 echo "\n$label, $unread " . __('New Items') . "\n\n"; 299 299 flush(); 300 300 … … 325 325 $unread = count($unreadIds); 326 326 list($label,$cls) = parent::magpieError($error); 327 echo "\n$label, $unread " . LBL_UPDATE_UNREAD. "<br />";327 echo "\n$label, $unread " . __('New Items') . "<br />"; 328 328 flush(); 329 329 } … … 357 357 echo "$title ...\t"; 358 358 flush(); 359 echo "\n$label, $unread " . LBL_UPDATE_UNREAD. "\n\n";359 echo "\n$label, $unread " . __('New Items') . "\n\n"; 360 360 flush(); 361 361 } -
trunk/gregarius/cls/wrappers/feeds.php
r1315 r1561 60 60 } 61 61 62 function rss_feeds_folders_unread_count($label=LBL_UNREAD_PF) { 62 function rss_feeds_folders_unread_count($label=null) { 63 if ($label === null) { 64 $label=__('<strong id="%s" style="%s">(%d unread)</strong>'); 65 } 63 66 if (array_key_exists($GLOBALS['rss']->currentFeedsFolder->id,$GLOBALS['rss']->feedList->collapsed_folders)) { 64 67 $sCls = ($GLOBALS['rss']->currentFeedsFolder->isCollapsed?"display:inline":"display:none"); … … 68 71 69 72 switch( $GLOBALS['rss']->feedList -> columnTitle ) { 70 case LBL_TAG_FOLDERS:73 case __('Categories'): 71 74 $ret = rss_plugin_hook("rss.plugins.sidemenu.categoryunreadlabel", $ret); 72 75 break; 73 case LBL_H2_CHANNELS:76 case __('Feeds'): 74 77 $ret = rss_plugin_hook("rss.plugins.sidemenu.folderunreadlabel", $ret); 75 78 break; -
trunk/gregarius/cls/wrappers/header.php
r1500 r1561 132 132 function rss_footer_last_modif() { 133 133 $ts = getLastModif(); 134 return ($ts ? rss_locale_date ("%c", $ts) : LBL_FOOTER_LAST_MODIF_NEVER);134 return ($ts ? rss_locale_date ("%c", $ts) : __('Never')); 135 135 } 136 136 … … 140 140 141 141 if (rss_user_level() > RSS_USER_LEVEL_NOLEVEL) { 142 $ret .= sprintf( LBL_LOGGED_IN_AS, rss_user_name())143 ." | <a href=\"".getPath()."?logout\">". LBL_LOG_OUT."</a>\n";142 $ret .= sprintf(__('Logged in as <strong>%s</strong>'), rss_user_name()) 143 ." | <a href=\"".getPath()."?logout\">".__('Logout')."</a>\n"; 144 144 } else { 145 $ret .= LBL_NOT_LOGGED_IN146 ." | <a href=\"#\" onclick=\"miniloginform(); return false;\">". LBL_LOG_IN."</a>";145 $ret .= __('Not logged in') 146 ." | <a href=\"#\" onclick=\"miniloginform(); return false;\">".__('Login')."</a>"; 147 147 $ret .= "<div style=\"display:none\" id=\"loginformcontainer\">" 148 148 . '<form ' . 'onsubmit="return loginHandler();" ' . 'method="post" action="'.getPath().'">' 149 149 . '<div style="display:inline"><input style=" width:50px;" name="username" id="username" type="text" /></div>' 150 150 . '<div style="display:inline"><input style=" width:50px;" name="password" id="password" type="password" /></div>' 151 . '<div style="display:inline"><input type="submit" value="'. LBL_LOG_IN.'" /></div>'151 . '<div style="display:inline"><input type="submit" value="'.__('Login').'" /></div>' 152 152 . '</form>' 153 153 ."</div>\n"; -
trunk/gregarius/cls/wrappers/item.php
r1536 r1561 41 41 } 42 42 43 function rss_item_pl_title($label=LBL_PL_FOR) { 44 43 function rss_item_pl_title($label=null){ 44 if (null === $label) { 45 $label = __('Permalink for '); 46 } 45 47 if (getConfig('rss.output.usepermalinks')) { 46 48 list ($ply, $plm, $pld) = explode(":", rss_date("Y:m:d", $GLOBALS['rss'] -> currentItem -> date, false)); … … 197 199 } 198 200 */ 199 return (($GLOBALS['rss']->currentItem->isPubDate? LBL_POSTED:LBL_FETCHED). $date_lbl);201 return (($GLOBALS['rss']->currentItem->isPubDate?__('Posted: '):__('Fetched: ')). $date_lbl); 200 202 } 201 203 } … … 218 220 $a = "<a href=\"".getPath() ."author.php?author=$ea\">$a</a>"; 219 221 } 220 return LBL_BY. $a;222 return __(' by ') . $a; 221 223 } 222 224 } -
trunk/gregarius/cls/wrappers/searchform.php
r1544 r1561 85 85 ."\t\t\t<option value=\"".INFINE_RESULTS."\"" 86 86 .((array_key_exists(QUERY_RESULTS,$_REQUEST) && $_REQUEST[QUERY_RESULTS] == INFINE_RESULTS?" selected=\"selected\"":"")) 87 .">". LBL_ALL."</option>\n"87 .">".__('All')."</option>\n" 88 88 ."\t\t</select>"; 89 89 } … … 94 94 ."\t\t\t<option value=\"". ALL_CHANNELS_ID ."\"" 95 95 .((!array_key_exists(QUERY_CHANNEL,$_REQUEST) || $_REQUEST[QUERY_CHANNEL] == ALL_CHANNELS_ID)?" selected=\"selected\"":"") 96 .">" . LBL_ALL. "</option>\n";96 .">" . __('All') . "</option>\n"; 97 97 98 98 $sql = "select " … … 120 120 } 121 121 if ($parent_ == "") { 122 $parent_ = LBL_HOME_FOLDER;122 $parent_ = __('Root'); 123 123 } 124 124 $ret .= "\t\t\t<optgroup label=\"$parent_ /\">\n"; -
trunk/gregarius/cls/wrappers/toolkit.php
r1551 r1561 40 40 $ret .= "\t<option value=\"$id\"" 41 41 .($selected > -1 && $selected == $id ? " selected=\"selected\"":"") 42 .">" . (($name == "")? LBL_HOME_FOLDER:$name) ."</option>\n";42 .">" . (($name == "")?__('Root'):$name) ."</option>\n"; 43 43 } 44 44 $ret .= "</select>\n"; … … 51 51 ."\t\t\t<option value=\"". $all_channels_id ."\"" 52 52 .(0 == $selected?" selected=\"selected\"":"") 53 .">" . LBL_ALL. "</option>\n";53 .">" . __('All') . "</option>\n"; 54 54 55 55 $sql = "select " … … 79 79 } 80 80 if ($parent_ == "") { 81 $parent_ = LBL_HOME_FOLDER;81 $parent_ = __('Root'); 82 82 } 83 83 $ret .= "\t\t\t<optgroup label=\"$parent_ /\">\n";
