diff options
author | Starla Insigna <hatkirby@fourisland.com> | 2009-05-18 09:27:25 -0400 |
---|---|---|
committer | Starla Insigna <hatkirby@fourisland.com> | 2009-05-18 09:27:25 -0400 |
commit | aefe1e9de37eee81f2804fd508b131dbfdb882cc (patch) | |
tree | 56bede70408372df04f2e7d783c871e8ec72dac3 | |
parent | ce73c00ce2e9a9a686d0e6b09bf25f896f454ac4 (diff) | |
download | fourisland-aefe1e9de37eee81f2804fd508b131dbfdb882cc.tar.gz fourisland-aefe1e9de37eee81f2804fd508b131dbfdb882cc.tar.bz2 fourisland-aefe1e9de37eee81f2804fd508b131dbfdb882cc.zip |
Fixed RSS feeds
-rwxr-xr-x | rss.php | 28 |
1 files changed, 24 insertions, 4 deletions
diff --git a/rss.php b/rss.php index e6e7d55..41e49f0 100755 --- a/rss.php +++ b/rss.php | |||
@@ -166,8 +166,28 @@ if (!isset($_GET['mode']) || ($_GET['mode'] == 'comments')) | |||
166 | $getcomments2 = mysql_query($getcomments); | 166 | $getcomments2 = mysql_query($getcomments); |
167 | while ($items[$i] = mysql_fetch_array($getcomments2)) | 167 | while ($items[$i] = mysql_fetch_array($getcomments2)) |
168 | { | 168 | { |
169 | if ($items[$i]['is_anon'] == 0) | ||
170 | { | ||
171 | $getuser = "SELECT * FROM phpbb_users WHERE user_id = " . $items[$i]['user_id']; | ||
172 | $getuser2 = mysql_query($getuser); | ||
173 | $getuser3 = mysql_fetch_array($getuser2); | ||
174 | |||
175 | $username = $getuser3['username']; | ||
176 | } else if ($items[$i]['is_anon'] == 1) | ||
177 | { | ||
178 | $getanon = "SELECT * FROM anon_commenters WHERE id = " . $items[$i]['user_id']; | ||
179 | $getanon2 = mysql_query($getanon); | ||
180 | $getanon3 = mysql_fetch_array($getanon2); | ||
181 | |||
182 | if ($getanon3['id'] == $items[$i]['user_id']) | ||
183 | { | ||
184 | $username = $getanon3['username'] . ' (Guest)'; | ||
185 | } | ||
186 | } | ||
187 | |||
169 | $items[$i]['sortDate'] = strtotime($items[$i]['posttime']); | 188 | $items[$i]['sortDate'] = strtotime($items[$i]['posttime']); |
170 | $items[$i]['itemType'] = 'comment'; | 189 | $items[$i]['itemType'] = 'comment'; |
190 | $items[$i]['username'] = $username; | ||
171 | 191 | ||
172 | $page_id = $items[$i]['page_id']; | 192 | $page_id = $items[$i]['page_id']; |
173 | $comType = substr($page_id,0,strpos($page_id,'-')); | 193 | $comType = substr($page_id,0,strpos($page_id,'-')); |
@@ -180,15 +200,15 @@ if (!isset($_GET['mode']) || ($_GET['mode'] == 'comments')) | |||
180 | $getpost2 = mysql_query($getpost); | 200 | $getpost2 = mysql_query($getpost); |
181 | $getpost3 = mysql_fetch_array($getpost2); | 201 | $getpost3 = mysql_fetch_array($getpost2); |
182 | 202 | ||
183 | $items[$i]['title'] = $getpost3['title']; | 203 | $items[$i]['title'] = '"' . $getpost3['title'] . '"'; |
184 | $items[$i]['url'] = 'blog/' . $getpost3['slug'] . '/'; | 204 | $items[$i]['url'] = 'blog/' . $getpost3['slug'] . '/'; |
185 | break; | 205 | break; |
186 | case 'poll': | 206 | case 'polloftheweek': |
187 | $getpoll = "SELECT * FROM polloftheweek WHERE id = " . $comID; | 207 | $getpoll = "SELECT * FROM polloftheweek WHERE id = " . $comID; |
188 | $getpoll2 = mysql_query($getpoll); | 208 | $getpoll2 = mysql_query($getpoll); |
189 | $getpoll3 = mysql_fetch_array($getpoll2); | 209 | $getpoll3 = mysql_fetch_array($getpoll2); |
190 | 210 | ||
191 | $items[$i]['title'] = $getpoll3['question']; | 211 | $items[$i]['title'] = '"' . $getpoll3['question'] . '"'; |
192 | $items[$i]['url'] = 'poll/' . $getpoll3['id'] . '.php'; | 212 | $items[$i]['url'] = 'poll/' . $getpoll3['id'] . '.php'; |
193 | break; | 213 | break; |
194 | case 'quote': | 214 | case 'quote': |
@@ -196,7 +216,7 @@ if (!isset($_GET['mode']) || ($_GET['mode'] == 'comments')) | |||
196 | $getquote2 = mysql_query($getquote); | 216 | $getquote2 = mysql_query($getquote); |
197 | $getquote3 = mysql_fetch_array($getquote2); | 217 | $getquote3 = mysql_fetch_array($getquote2); |
198 | 218 | ||
199 | $items[$i]['title'] = '#' . $getquote3['id']; | 219 | $items[$i]['title'] = 'Quote #' . $getquote3['id']; |
200 | $items[$i]['url'] = 'quotes/' . $getquote3['id'] . '.php'; | 220 | $items[$i]['url'] = 'quotes/' . $getquote3['id'] . '.php'; |
201 | break; | 221 | break; |
202 | } | 222 | } |