Differences

This shows you the differences between the selected revision and the current version of the page.

punbb13:syndication 2009/07/08 13:10 punbb13:syndication 2020/02/06 11:04 current
Line 1: Line 1:
====== Syndication ====== ====== Syndication ======
-This script is used to include information about your board from+**extern.php** is used to include information about your board from
pages outside the forums and to syndicate news about recent pages outside the forums and to syndicate news about recent
-discussions via RSS / Atom / XML. The script can display a list of+discussions via RSS / Atom / XML. The script is able to display a list of
recent discussions, a list of active users or a collection of recent discussions, a list of active users or a collection of
-general board statistics. The script can be called directly via+general board statistics. It can be called directly via
an URL, from a PHP include command or through the use of Server an URL, from a PHP include command or through the use of Server
Side Includes (SSI). Side Includes (SSI).
-The scripts behaviour is controlled via variables supplied in the+The script behaviour is controlled via variables supplied in the
URL to the script. The different variables are: action (what to URL to the script. The different variables are: action (what to
do), show (how many items to display), fid (the ID or ID's of do), show (how many items to display), fid (the ID or ID's of
Line 34: Line 34:
  * **show:** Any integer value between 1 and 50. The default is 15.   * **show:** Any integer value between 1 and 50. The default is 15.
 +
 +==== Examples ====
 +
 +== Here are some examples using PHP include(). ==
 +
 +  * Show board statistics:
 +include('http://host.com/extern.php?action=stats');
 +  * Show the 10 newest topics from forums with ID 5, 6 and 7:
 +include('http://host.com/extern.php?action=feed&show=10&fid=5,6,7');
 +  * Show users online:
 +include('http://host.com/forums/extern.php?action=online');
 +  * Show users online with full listing of users:
 +include('http://host.com/forums/extern.php?action=online_full');
 +
 +== And finally some examples using extern.php to output an RSS, ATOM, XML, HTML feed. ==
 +
 +  * Output feed as RSS 2.0:
 +http://host.com/extern.php?action=feed&type=rss
 +  * Output feed as Atom 1.0:
 +http://host.com/extern.php?action=feed&type=atom
 +  * Output feed as XML:
 +http://host.com/extern.php?action=feed&type=xml
 +  * Output feed as HTML:
 +http://host.com/extern.php?action=feed&type=html

Personal Tools