Changeset 812
Legend:
- Unmodified
- Added
- Removed
-
sitemaps/files/lib/page/SitemapsPage.class.php
r805 r812 2 2 // wcf imports 3 3 require_once(WCF_DIR.'lib/page/AbstractPage.class.php'); 4 5 // rewriter util6 require_once(WBB_DIR.'lib/page/PublicSEORewriter.class.php');7 4 8 5 /** … … 17 14 18 15 public $index = false; 19 public $rewriter;20 16 21 17 /** … … 28 24 $this->index = true; 29 25 } 30 31 $this->rewriter = new PublicSEORewriter();32 26 } 33 27 -
sitemaps/optionals/de.easy-coding.wbb.sitemaps/files/lib/system/event/listener/SitemapsPageWBBListener.class.php
r444 r812 6 6 require_once(WBB_DIR.'lib/data/board/SitemapsBoard.class.php'); 7 7 require_once(WBB_DIR.'lib/data/thread/SitemapsThread.class.php'); 8 9 // rewriter util 10 require_once(WBB_DIR.'lib/page/PublicSEORewriterWBB.class.php'); 8 11 9 12 /** … … 23 26 protected $eventObj; 24 27 protected $className; 28 29 protected $rewriter; 25 30 26 31 /** … … 30 35 $this->eventObj = $eventObj; 31 36 $this->className = $className; 37 38 $this->rewriter = new PublicSEORewriterWBB(); 32 39 33 40 switch ($eventName) { … … 110 117 $tmp = new SitemapsThread($row); 111 118 112 if($this-> eventObj->rewriter === null) {119 if($this->rewriter === null) { 113 120 $tmp->url = sprintf('index.php?page=Thread&threadID=%d', $row['threadID']); 114 121 } else { 115 $this-> eventObj->rewriter->publicCacheThreads($row['threadID'], $row);116 $tmp->url = $this-> eventObj->rewriter->publicParseThreadURLs($row['threadID'], '');122 $this->rewriter->publicCacheThreads($row['threadID'], $row); 123 $tmp->url = $this->rewriter->publicParseThreadURLs($row['threadID'], ''); 117 124 } 118 125 … … 123 130 $tmp = new SitemapsThread($row['threadID'], $row); 124 131 125 if($this-> eventObj->rewriter === null) {132 if($this->rewriter === null) { 126 133 $tmp->url = sprintf('index.php?page=Thread&threadID=%d&pageNo=%d', $row['threadID'], $j); 127 134 } else { 128 $tmp->url = $this-> eventObj->rewriter->publicParseMultipleThreadURLs($row['threadID'], $j, '');135 $tmp->url = $this->rewriter->publicParseMultipleThreadURLs($row['threadID'], $j, ''); 129 136 } 130 137 … … 134 141 135 142 // titles are not used again.. clear cache 136 if($this-> eventObj->rewriter !== null) $this->eventObj->rewriter->clearCache();143 if($this->rewriter !== null) $this->rewriter->clearCache(); 137 144 } 138 145 } … … 175 182 } 176 183 177 if($this-> eventObj->rewriter === null) {184 if($this->rewriter === null) { 178 185 $this->boards[$i]->url = sprintf('index.php?page=Board&boardID=%d', $row['boardID']); 179 186 } else { 180 $this->boards[$i]->url = $this-> eventObj->rewriter->publicParseBoardURLs($row['boardID'], '');187 $this->boards[$i]->url = $this->rewriter->publicParseBoardURLs($row['boardID'], ''); 181 188 } 182 189 … … 189 196 $this->boards[$i]->time = $row['lastPostTime']; 190 197 191 if($this-> eventObj->rewriter === null) {198 if($this->rewriter === null) { 192 199 $this->boards[$i]->url = sprintf('index.php?page=Board&boardID=%d&pageNo=%d', $row['boardID'], $j); 193 200 } else { 194 $this->boards[$i]->url = $this-> eventObj->rewriter->publicParseMultipleBoardURLs($row['boardID'], $j, '');201 $this->boards[$i]->url = $this->rewriter->publicParseMultipleBoardURLs($row['boardID'], $j, ''); 195 202 } 196 203 } … … 200 207 201 208 // titles are not used again.. clear cache 202 if($this-> eventObj->rewriter !== null) $this->eventObj->rewriter->clearCache();209 if($this->rewriter !== null) $this->rewriter->clearCache(); 203 210 } 204 211 }
