3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the Revised BSD License.
6 This program is distributed in the hope that it will be useful,
7 but WITHOUT ANY WARRANTY; without even the implied warranty of
8 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9 Revised BSD License for more details.
11 Copyright 2004-2014 iDB Support - http://idb.berlios.de/
12 Copyright 2004-2014 Game Maker 2k - http://gamemaker2k.org/
14 $FileInfo: rssfeed.php - Last Update: 07/10/2014 SVN 788 - Author: cooldude2k $
16 $File3Name = basename($_SERVER['SCRIPT_NAME']);
17 if ($File3Name=="rssfeed.php"||$File3Name=="/rssfeed.php") {
20 if(!isset($_GET['debug'])) { $_GET['debug'] = null; }
21 if(!is_numeric($_GET['id'])) { $_GET['id'] = null; }
22 $boardsname = htmlentities($Settings['board_name'], ENT_QUOTES, $Settings['charset']);
23 $boardsname = preg_replace("/&#(x[a-f0-9]+|[0-9]+);/i", "&#$1;", $boardsname);
24 $_GET['feedtype'] = strtolower($_GET['feedtype']);
25 if($_GET['feedtype']!="rss"&&$_GET['feedtype']!="atom"&&$_GET['feedtype']!="oldrss"&&
26 $_GET['feedtype']!="opml"&&$_GET['feedtype']!="opensearch") {
27 $_GET['feedtype'] = "rss"; }
28 //$basepath = pathinfo($_SERVER['REQUEST_URI']);
29 /*if(dirname($_SERVER['REQUEST_URI'])!="."||
30 dirname($_SERVER['REQUEST_URI'])!=null) {
31 $basedir = dirname($_SERVER['REQUEST_URI'])."/"; }*/
32 if(dirname($_SERVER['SCRIPT_NAME'])!="."||
33 dirname($_SERVER['SCRIPT_NAME'])!=null) {
34 $basedir = dirname($_SERVER['SCRIPT_NAME'])."/"; }
35 if($basedir==null||$basedir==".") {
36 if(dirname($_SERVER['SCRIPT_NAME'])=="."||
37 dirname($_SERVER['SCRIPT_NAME'])==null) {
38 $basedir = dirname($_SERVER['PHP_SELF'])."/"; } }
39 if($basedir=="\/") { $basedir="/"; }
40 $basedir = str_replace("//", "/", $basedir);
41 if($Settings['fixpathinfo']!="on"&&
42 $Settings['fixpathinfo']!="off"&&
43 $Settings['fixpathinfo']!==null) {
44 $basedir = "/"; } $BaseURL = $basedir;
45 if(!isset($_SERVER['HTTPS'])) { $_SERVER['HTTPS'] = 'off'; }
46 if($_SERVER['HTTPS']=="on") { $prehost = "https://"; }
47 if($_SERVER['HTTPS']!="on") { $prehost = "http://"; }
48 if($Settings['idburl']=="localhost"||$Settings['idburl']==null) {
49 $BoardURL = $prehost.$_SERVER["HTTP_HOST"].$BaseURL; }
50 if($Settings['idburl']!="localhost"&&$Settings['idburl']!=null) {
51 $BoardURL = $Settings['idburl'];
52 if($Settings['qstr']!="/") {
53 $AltBoardURL = $BoardURL; }
54 if($Settings['qstr']=="/") {
55 $AltBoardURL = preg_replace("/\/$/","",$BoardURL); } }
56 if ($_GET['id']==null) { $_GET['id']="1"; }
57 if($rssurlon=="on") { $BoardURL = $rssurl; }
58 $feedsname = basename($_SERVER['SCRIPT_NAME']);
59 if($_SERVER['PATH_INFO']!=null) {
60 $feedsname .= htmlentities($_SERVER['PATH_INFO'], ENT_QUOTES, $Settings['charset']); }
61 if($_SERVER['QUERY_STRING']!=null) {
62 $feedsname .= "?".htmlentities($_SERVER['QUERY_STRING'], ENT_QUOTES, $Settings['charset']); }
63 $checkfeedtype = "application/rss+xml";
64 if($_GET['feedtype']=="oldrss") { $checkfeedtype = "application/xml"; }
65 if($_GET['feedtype']=="rss") { $checkfeedtype = "application/rss+xml"; }
66 if($_GET['feedtype']=="atom") { $checkfeedtype = "application/atom+xml"; }
67 if($_GET['feedtype']=="opml") { $checkfeedtype = "text/x-opml"; }
68 if($_GET['feedtype']=="opensearch") { $checkfeedtype = "application/opensearchdescription+xml"; }
69 if(stristr($_SERVER["HTTP_ACCEPT"],$checkfeedtype) ) {
70 header("Content-Type: ".$checkfeedtype."; charset=".$Settings['charset']); }
71 else { if(stristr($_SERVER["HTTP_ACCEPT"],"application/xml") ) {
72 header("Content-Type: application/xml; charset=".$Settings['charset']); }
73 else { if (stristr($_SERVER["HTTP_USER_AGENT"],"FeedValidator")) {
74 header("Content-Type: application/xml; charset=".$Settings['charset']);
75 } else { header("Content-Type: text/xml; charset=".$Settings['charset']); } } }
76 header("Content-Language: en");
77 header("Vary: Accept");
78 if($_GET['feedtype']=="oldrss"||$_GET['feedtype']=="rss"||$_GET['feedtype']=="atom"||$_GET['feedtype']=="opml") {
79 $prequery = sql_pre_query("SELECT * FROM \"".$Settings['sqltable']."forums\" WHERE \"id\"=%i".$ForumIgnoreList2."", array($_GET['id']));
80 $preresult=sql_query($prequery,$SQLStat);
81 $prenum=sql_num_rows($preresult);
83 if($prenum==0) { redirect("location",$rbasedir.url_maker($exfile['index'],$Settings['file_ext'],"act=view",$Settings['qstr'],$Settings['qsep'],$prexqstr['index'],$exqstr['index'],false)); sql_free_result($preresult);
84 ob_clean(); header("Content-Type: text/plain; charset=".$Settings['charset']); $urlstatus = 302;
85 gzip_page($Settings['use_gzip'],$GZipEncode['Type']); session_write_close(); die(); }
86 $ForumID=sql_result($preresult,0,"id");
87 $ForumName=sql_result($preresult,0,"Name");
88 $ForumName = htmlentities($ForumName, ENT_QUOTES, $Settings['charset']);
89 $ForumName = preg_replace("/&#(x[a-f0-9]+|[0-9]+);/i", "&#$1;", $ForumName);
90 $ForumCatID=sql_result($preresult,0,"CategoryID");
91 $ForumType=sql_result($preresult,0,"ForumType");
92 $ForumType = strtolower($ForumType);
93 sql_free_result($preresult);
94 if($PermissionInfo['CanViewForum'][$ForumID]=="no"||
95 $PermissionInfo['CanViewForum'][$ForumID]!="yes") {
96 redirect("location",$rbasedir.url_maker($exfile['index'],$Settings['file_ext'],"act=view",$Settings['qstr'],$Settings['qsep'],$prexqstr['index'],$exqstr['index'],false));
97 ob_clean(); header("Content-Type: text/plain; charset=".$Settings['charset']); $urlstatus = 302;
98 gzip_page($Settings['use_gzip'],$GZipEncode['Type']); session_write_close(); die(); }
99 if($CatPermissionInfo['CanViewCategory'][$ForumCatID]=="no"||
100 $CatPermissionInfo['CanViewCategory'][$ForumCatID]!="yes") {
101 redirect("location",$rbasedir.url_maker($exfile['index'],$Settings['file_ext'],"act=view",$Settings['qstr'],$Settings['qsep'],$prexqstr['index'],$exqstr['index'],false));
102 ob_clean(); header("Content-Type: text/plain; charset=".$Settings['charset']); $urlstatus = 302;
103 gzip_page($Settings['use_gzip'],$GZipEncode['Type']); session_write_close(); die(); }
104 $gltf = array(null); $gltf[0] = $ForumID;
105 if ($ForumType=="subforum") {
106 $apcquery = sql_pre_query("SELECT * FROM \"".$Settings['sqltable']."forums\" WHERE \"ShowForum\"='yes' AND \"InSubForum\"=%i".$ForumIgnoreList2." ORDER BY \"id\"", array($ForumID));
107 $apcresult=sql_query($apcquery,$SQLStat);
108 $apcnum=sql_num_rows($apcresult);
109 $apci=0; $apcl=1; if($apcnum>=1) {
110 while ($apci < $apcnum) {
111 $SubsForumID=sql_result($apcresult,$apci,"id");
112 if(isset($PermissionInfo['CanViewForum'][$SubsForumID])&&
113 $PermissionInfo['CanViewForum'][$SubsForumID]=="yes") {
114 $gltf[$apcl] = $SubsForumID; ++$apcl; }
116 sql_free_result($apcresult); } }
117 $Atom = null; $RSS = null; $PreRSS = null;
118 $gltnum = count($gltf); $glti = 0;
119 while ($glti < $gltnum) {
120 $ExtraIgnores = null;
121 if($PermissionInfo['CanModForum'][$gltf[$glti]]=="no") {
122 $ExtraIgnores = " AND \"Closed\"<>3"; }
123 $query = sql_pre_query("SELECT * FROM \"".$Settings['sqltable']."topics\" WHERE \"ForumID\"=%i".$ExtraIgnores.$ForumIgnoreList4." ORDER BY \"LastUpdate\" DESC LIMIT %i", array($gltf[$glti],$Settings['max_topics']));
124 $result=sql_query($query,$SQLStat);
125 $num=sql_num_rows($result); $i=0;
127 $TopicID=sql_result($result,$i,"id");
128 $ForumID=sql_result($result,$i,"ForumID");
129 $CategoryID=sql_result($result,$i,"CategoryID");
130 $pquery = sql_pre_query("SELECT * FROM \"".$Settings['sqltable']."posts\" WHERE \"TopicID\"=%i ORDER BY \"TimeStamp\" ASC LIMIT %i", array($TopicID,1));
131 $presult=sql_query($pquery,$SQLStat);
132 $pnum=sql_num_rows($presult);
133 $MyDescription=sql_result($presult,0,"Post");
134 $UsersID=sql_result($result,$i,"UserID");
135 $GuestsName=sql_result($result,$i,"GuestName");
136 $requery = sql_pre_query("SELECT * FROM \"".$Settings['sqltable']."members\" WHERE \"id\"=%i LIMIT 1", array($UsersID));
137 $reresult=sql_query($requery,$SQLStat);
138 $renum=sql_num_rows($reresult);
139 if($renum<1) { $UsersID = -1;
140 $requery = sql_pre_query("SELECT * FROM \"".$Settings['sqltable']."members\" WHERE \"id\"=%i LIMIT 1", array($UsersID));
141 $reresult=sql_query($requery,$SQLStat);
142 $renum=sql_num_rows($reresult); }
143 $memrequery = sql_pre_query("SELECT * FROM \"".$Settings['sqltable']."mempermissions\" WHERE \"id\"=%i LIMIT 1", array($UsersID));
144 $memreresult=sql_query($memrequery,$SQLStat);
145 $memrenum=sql_num_rows($memreresult);
146 $UsersName=sql_result($reresult,0,"Name");
147 $UsersGroupID=sql_result($reresult,0,"GroupID");
148 $PreUserCanExecPHP=sql_result($memreresult,0,"CanExecPHP");
149 if($PreUserCanExecPHP!="yes"&&$PreUserCanExecPHP!="no"&&$PreUserCanExecPHP!="group") {
150 $PreUserCanExecPHP = "no"; }
151 $PreUserCanDoHTML=sql_result($memreresult,0,"CanDoHTML");
152 if($PreUserCanDoHTML!="yes"&&$PreUserCanDoHTML!="no"&&$PreUserCanDoHTML!="group") {
153 $PreUserCanDoHTML = "no"; }
154 $PreUserCanUseBBags=sql_result($memreresult,0,"CanUseBBags");
155 if($PreUserCanUseBBags!="yes"&&$PreUserCanUseBBags!="no"&&$PreUserCanUseBBags!="group") {
156 $PreUserCanUseBBags = "no"; }
157 sql_free_result($memreresult);
158 if($UsersName=="Guest") { $UsersName=$GuestsName;
159 if($UsersName==null) { $UsersName="Guest"; } }
160 sql_free_result($reresult);
161 $gquery = sql_pre_query("SELECT * FROM \"".$Settings['sqltable']."groups\" WHERE \"id\"=%i LIMIT 1", array($UsersGroupID));
162 $gresult=sql_query($gquery,$SQLStat);
163 $UsersGroup=sql_result($gresult,0,"Name");
164 $User1CanExecPHP = $PreUserCanExecPHP;
165 if($PreUserCanExecPHP=="group") {
166 $User1CanExecPHP=sql_result($gresult,0,"CanExecPHP"); }
167 if($User1CanExecPHP!="yes"&&$User1CanExecPHP!="no") {
168 $User1CanExecPHP = "no"; }
169 $User1CanDoHTML = $PreUserCanDoHTML;
170 if($PreUserCanDoHTML=="group") {
171 $User1CanDoHTML=sql_result($gresult,0,"CanDoHTML"); }
172 if($User1CanDoHTML!="yes"&&$User1CanDoHTML!="no") {
173 $User1CanDoHTML = "no"; }
174 $User1CanUseBBags = $PreUserCanUseBBags;
175 if($User1CanUseBBags=="group") {
176 $User1CanUseBBags=sql_result($gresult,0,"CanUseBBags"); }
177 if($User1CanUseBBags!="yes"&&$User1CanUseBBags!="no") {
178 $User1CanUseBBags = "no"; }
179 $GroupNamePrefix=sql_result($gresult,0,"NamePrefix");
180 $GroupNameSuffix=sql_result($gresult,0,"NameSuffix");
181 sql_free_result($gresult);
182 if($User1CanUseBBags=="yes") { $MyDescription = bbcode_parser($MyDescription); }
183 if($User1CanExecPHP=="no") {
184 $MyDescription = preg_replace("/\[ExecPHP\](.*?)\[\/ExecPHP\]/is","<span style=\"color: red; font-weight: bold;\">ERROR:</span> cannot execute php code.",$MyDescription); }
185 if($User1CanExecPHP=="yes") { $MyDescription = php_execute($MyDescription); }
186 if($User1CanDoHTML=="no") {
187 $MyDescription = preg_replace("/\[DoHTML\](.*?)\[\/DoHTML\]/is","<span style=\"color: red; font-weight: bold;\">ERROR:</span> cannot execute html.",$MyDescription); }
188 if($User1CanDoHTML=="yes") { $MyDescription = do_html_bbcode($MyDescription); }
189 $MyDescription = text2icons($MyDescription,$Settings['sqltable'],$SQLStat);
190 $MyDescription = preg_replace("/\<br\>/", "<br />", nl2br($MyDescription));
191 $MyDescription = url2link($MyDescription);
192 if(isset($GroupNamePrefix)&&$GroupNamePrefix!=null) {
193 $UsersName = $GroupNamePrefix.$UsersName; }
194 if(isset($GroupNameSuffix)&&$GroupNameSuffix!=null) {
195 $UsersName = $UsersName.$GroupNameSuffix; }
196 $TheTime=sql_result($result,$i,"TimeStamp");
197 $AtomTime=GMTimeChange("Y-m-d\TH:i:s\Z",$TheTime,0);
198 //$OldRSSTime=GMTimeChange("Y-m-d\TH:i:s+0:00",$TheTime,0);
199 $OldRSSTime=$AtomTime;
200 $TheTime=GMTimeChange("D, j M Y G:i:s \G\M\T",$TheTime,0);
201 $TopicName=sql_result($result,$i,"TopicName");
202 $ForumDescription=sql_result($result,$i,"Description");
203 if(isset($PermissionInfo['CanViewForum'][$ForumID])&&
204 $PermissionInfo['CanViewForum'][$ForumID]=="yes"&&
205 isset($CatPermissionInfo['CanViewCategory'][$CategoryID])&&
206 $CatPermissionInfo['CanViewCategory'][$CategoryID]=="yes") {
207 if($_GET['feedtype']=="atom") {
208 $CDataDescription = "<![CDATA[\n".$MyDescription."\n]]>";
209 $Atom .= '<entry>'."\n".'<title>'.$TopicName.'</title>'."\n".'<summary>'.$CDataDescription.'</summary>'."\n".'<link rel="alternate" href="'.$BoardURL.url_maker($exfilerss['topic'],$Settings['file_ext'],"act=view&id=".$TopicID."&page=1",$Settings['qstr'],$Settings['qsep'],$prexqstrrss['topic'],$exqstrrss['topic']).'" />'."\n".'<id>'.$BoardURL.url_maker($exfilerss['topic'],$Settings['file_ext'],"act=view&id=".$TopicID."&page=1",$Settings['qstr'],$Settings['qsep'],$prexqstrrss['topic'],$exqstrrss['topic']).'</id>'."\n".'<author>'."\n".'<name>'.$UsersName.'</name>'."\n".'</author>'."\n".'<updated>'.$AtomTime.'</updated>'."\n".'</entry>'."\n"; }
210 if($_GET['feedtype']=="oldrss") {
211 $CDataDescription = "<![CDATA[\n".$MyDescription."\n]]>";
212 $PreRSS .= ' <rdf:li rdf:resource="'.$BoardURL.url_maker($exfilerss['topic'],$Settings['file_ext'],"act=view&id=".$TopicID."&page=1",$Settings['qstr'],$Settings['qsep'],$prexqstrrss['topic'],$exqstrrss['topic']).'" />'."\n";
213 $RSS .= '<item rdf:about="'.$BoardURL.url_maker($exfilerss['topic'],$Settings['file_ext'],"act=view&id=".$TopicID."&page=1",$Settings['qstr'],$Settings['qsep'],$prexqstrrss['topic'],$exqstrrss['topic']).'">'."\n".'<title>'.$TopicName.'</title>'."\n".'<description>'.$CDataDescription.'</description>'."\n".'<dc:publisher>'.$UsersName.'</dc:publisher>'."\n".'<dc:creator>'.$UsersName.'</dc:creator>'."\n".'<dc:date>'.$OldRSSTime.'</dc:date>'."\n".'</item>'."\n"; }
214 if($_GET['feedtype']=="rss") {
215 $CDataDescription = "<![CDATA[\n".$MyDescription."\n]]>";
216 $RSS .= '<item>'."\n".'<pubDate>'.$TheTime.'</pubDate>'."\n".'<author>'.$UsersName.'</author>'."\n".'<title>'.$TopicName.'</title>'."\n".'<description>'.$CDataDescription.'</description>'."\n".'<link>'.$BoardURL.url_maker($exfilerss['topic'],$Settings['file_ext'],"act=view&id=".$TopicID."&page=1",$Settings['qstr'],$Settings['qsep'],$prexqstrrss['topic'],$exqstrrss['topic']).'</link>'."\n".'<guid>'.$BoardURL.url_maker($exfilerss['topic'],$Settings['file_ext'],"act=view&id=".$TopicID."&page=1",$Settings['qstr'],$Settings['qsep'],$prexqstrrss['topic'],$exqstrrss['topic']).'</guid>'."\n".'</item>'."\n"; } }
217 ++$i; sql_free_result($presult); }
218 sql_free_result($result);
220 $endtag = " <!-- Renee Sabonis ^_^ -->\n";
221 xml_doc_start("1.0",$Settings['charset']);
222 if($Settings['showverinfo']=="on") { ?>
223 <!-- generator="<?php echo $VerInfo['iDB_Ver_Show']; ?>" -->
224 <?php } if($Settings['showverinfo']!="on") { ?>
225 <!-- generator="<?php echo $iDB; ?>" -->
226 <?php } echo "\n"; if($_GET['feedtype']=="oldrss") { ?>
228 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
229 xmlns="http://purl.org/rss/1.0/"
230 xmlns:dc="http://purl.org/dc/elements/1.1/"
232 <channel rdf:about="<?php echo $BoardURL.$feedsname; ?>">
233 <title><?php echo $boardsname." ".$ThemeSet['TitleDivider']; ?> Viewing Forum <?php echo $ForumName; ?></title>
234 <link><?php echo $BoardURL.url_maker($exfile[$ForumType],$Settings['file_ext'],"act=view&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr[$ForumType],$exqstr[$ForumType]); ?></link>
235 <description>RSS Feed of the Topics in Forum <?php echo $ForumName; ?></description>
236 <image rdf:resource="<?php echo $AltBoardURL.$SettDir['inc']; ?>rss.gif" />
240 <?php echo $PreRSS; ?>
245 <image rdf:about="<?php echo $AltBoardURL.$SettDir['inc']; ?>rss.gif">
246 <title><?php echo $boardsname; ?></title>
247 <link><?php echo $BoardURL.url_maker($exfile[$ForumType],$Settings['file_ext'],"act=view&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr[$ForumType],$exqstr[$ForumType]); ?></link>
248 <url><?php echo $AltBoardURL.$SettDir['inc']; ?>rss.gif</url>
250 <!-- Renee Sabonis ^_^ -->
251 <?php echo "\n".$RSS."\n"; ?></rdf:RDF>
252 <?php } if($_GET['feedtype']=="rss") { ?>
255 <title><?php echo $boardsname." ".$ThemeSet['TitleDivider']; ?> Viewing Forum <?php echo $ForumName; ?></title>
256 <description>RSS Feed of the Topics in Forum <?php echo $ForumName; ?></description>
257 <link><?php echo $BoardURL.url_maker($exfile[$ForumType],$Settings['file_ext'],"act=view&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr[$ForumType],$exqstr[$ForumType]); ?></link>
258 <language>en</language>
259 <?php if($Settings['showverinfo']=="on") { ?>
260 <generator><?php echo $VerInfo['iDB_Ver_Show']; ?></generator>
261 <?php } if($Settings['showverinfo']!="on") { ?>
262 <generator><?php echo $iDB; ?></generator>
263 <?php } echo "\n"; ?>
264 <copyright><?php echo $SettInfo['Author']; ?></copyright>
267 <url><?php echo $AltBoardURL.$SettDir['inc']; ?>rss.gif</url>
268 <title><?php echo $boardsname; ?></title>
269 <link><?php echo $AltBoardURL; ?></link>
271 <?php echo $endtag; ?>
272 <?php echo "\n".$RSS."\n"; ?></channel>
274 <?php } if($_GET['feedtype']=="atom") { ?>
275 <feed xmlns="http://www.w3.org/2005/Atom">
276 <title><?php echo $boardsname." ".$ThemeSet['TitleDivider']; ?> Viewing Forum <?php echo $ForumName; ?></title>
277 <subtitle>Atom Feed of the Topics in Forum <?php echo $ForumName; ?></subtitle>
278 <link rel="self" href="<?php echo $BoardURL.$feedsname; ?>" />
279 <id><?php echo $BoardURL.url_maker($exfile[$ForumType],$Settings['file_ext'],"act=view&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr[$ForumType],$exqstr[$ForumType]); ?></id>
280 <updated><?php echo gmdate("Y-m-d\TH:i:s\Z"); ?></updated>
281 <?php if($Settings['showverinfo']=="on") { ?>
282 <generator><?php echo $VerInfo['iDB_Ver_Show']; ?></generator>
283 <?php } if($Settings['showverinfo']!="on") { ?>
284 <generator><?php echo $iDB; ?></generator>
286 <icon><?php echo $AltBoardURL.$SettDir['inc']; ?>rss.gif</icon>
287 <?php echo $endtag; ?>
288 <?php echo "\n".$Atom."\n"; ?>
290 <?php } if($_GET['feedtype']=="opml") { ?>
293 <dateCreated><?php echo gmdate("d-M-Y"); ?></dateCreated>
297 <outline text="<?php echo $ForumName; ?> Topics RSS 1.0 Feed" type="link" url="<?php echo $BoardURL.url_maker($exfile['index'],$Settings['file_ext'],"act=view",$Settings['qstr'],$Settings['qsep'],$prexqstr['index'],$exqstr['index']); ?>" htmlUrl="<?php echo $BoardURL.url_maker($exfile[$ForumType],$Settings['file_ext'],"act=view&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr[$ForumType],$exqstr[$ForumType]); ?>" xmlUrl="<?php echo $BoardURL.url_maker($exfile['rss'],$Settings['rss_ext'],"act=oldrss&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr['rss'],$exqstr['rss']); ?>" />
299 <outline text="<?php echo $ForumName; ?> Topics RSS 2.0 Feed" type="rss" url="<?php echo $BoardURL.url_maker($exfile['index'],$Settings['file_ext'],"act=view",$Settings['qstr'],$Settings['qsep'],$prexqstr['index'],$exqstr['index']); ?>" htmlUrl="<?php echo $BoardURL.url_maker($exfile[$ForumType],$Settings['file_ext'],"act=view&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr[$ForumType],$exqstr[$ForumType]); ?>" xmlUrl="<?php echo $BoardURL.url_maker($exfile['rss'],$Settings['rss_ext'],"act=rss&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr['rss'],$exqstr['rss']); ?>" />
300 <outline text="<?php echo $ForumName; ?> Topics Atom Feed" type="atom" url="<?php echo $BoardURL.url_maker($exfile['index'],$Settings['file_ext'],"act=view",$Settings['qstr'],$Settings['qsep'],$prexqstr['index'],$exqstr['index']); ?>" htmlUrl="<?php echo $BoardURL.url_maker($exfile[$ForumType],$Settings['file_ext'],"act=view&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr[$ForumType],$exqstr[$ForumType]); ?>" xmlUrl="<?php echo $BoardURL.url_maker($exfile['rss'],$Settings['rss_ext'],"act=atom&id=".$ForumID,$Settings['qstr'],$Settings['qsep'],$prexqstr['rss'],$exqstr['rss']); ?>" />
303 <?php echo $endtag; ?>
304 <?php } if($_GET['feedtype']=="opensearch") { ?>
305 <OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/"
306 xmlns:moz="http://www.mozilla.org/2006/browser/search/">
307 <ShortName><?php echo $boardsname." ".$ThemeSet['TitleDivider']; ?> Search</ShortName>
308 <Description><?php echo $SettInfo['Description']; ?></Description>
309 <InputEncoding><?php echo $Settings['charset']; ?></InputEncoding>
310 <Image width="16" height="16" type="image/x-icon"><?php echo $AltBoardURL.$ThemeSet['FavIcon']; ?></Image>
311 <Url type="text/html" method="POST" template="<?php echo $BoardURL.url_maker("search",$Settings['file_ext'],null,"search","search"); ?>">
312 <Param name="act" value="topics"/>
313 <Param name="search" value="{searchTerms}"/>
314 <Param name="type" value="wildcard"/>
315 <Param name="page" value="1"/>
317 <?php echo $endtag; ?>
318 <moz:SearchForm><?php echo $BoardURL.url_maker("search",$Settings['file_ext'],null,"search","search"); ?></moz:SearchForm>
319 </OpenSearchDescription>
320 <?php } if($_GET['debug']=="true"||$_GET['debug']=="on") {
321 function execution_time($starttime) {
322 list($uetime, $etime) = explode(" ", microtime());
323 $endtime = $uetime + $etime;
324 return bcsub($endtime, $starttime, 4); }
325 echo "<!-- execution_time=\"".execution_time($starttime)."\" -->"; }
326 gzip_page($Settings['use_gzip'],$GZipEncode['Type']); ?>