Location: PHPKode > scripts > Syndication Classes > RSS.php
<?php

error_reporting ( E_ALL );

if ( isset ( $_GET['source'] ) AND $_GET['source'] == 1 )
{
	echo '<a href=\'./RSS.php\'>Back</a><br />';
	echo '<a href=\'./RSS.php?source=2\'>View SC_XML.class.php</a><br />';
	echo '<a href=\'./RSS.php?source=3\'>View RSS.php</a><br />';
	highlight_file ( './SC_RSS.class.php' );
	exit;
}
else if ( isset ( $_GET['source'] ) AND $_GET['source'] == 2 )
{
	echo '<a href=\'./RSS.php\'>Back</a><br />';
	echo '<a href=\'./RSS.php?source=1\'>View SC_RSS.class.php</a><br />';
	echo '<a href=\'./RSS.php?source=3\'>View RSS.php</a><br />';
	highlight_file ( './SC_XML.class.php' );
	exit;
}
else if ( isset ( $_GET['source'] ) AND $_GET['source'] == 3 )
{
	echo '<a href=\'./RSS.php\'>Back</a><br />';
	echo '<a href=\'./RSS.php?source=1\'>View SC_RSS.class.php</a><br />';
	echo '<a href=\'./RSS.php?source=2\'>View SC_XML.class.php</a><br />';
	highlight_file ( './RSS.php' );
	exit;
}

echo '<a href=\'./RSS.php?source=1\'>View SC_RSS.class.php</a><br />';
echo '<a href=\'./RSS.php?source=2\'>View SC_XML.class.php</a><br />';
echo '<a href=\'./RSS.php?source=3\'>View RSS.php</a><br />';

require_once "SC_RSS.class.php";

$info = Array (
	'title'       => 'Topic Title',
	'link'        => 'http://k4_bb_url.tld/viewtopic.php?id=234234',
	'description' => 'Some information on the topic',
	'pubDate'     => date ( 'r' ),
	'category'    => 'Forum Cat/Forum Name'
);

$RSS = new SC_RSS ( $info );
$RSS->debug = true;

// Add posts
$post[1] = Array (
	'title'       => 'Topic Title',
	'link'        => 'http://k4_bb_url.tld/viewtopic.php?id=25#25',
	'description' => 'The post goes here for real',
	'author'      => 'k4st',
	'guid'        => array('http://k4_bb_url.tld/viewtopic.php?id=25#25',true),
	'pubDate'     => date ( 'r' )
);
$post[2] = Array (
	'title'       => 'RE: Topic Title',
	'link'        => 'http://k4_bb_url.tld/viewtopic.php?id=25#26',
	'description' => 'This is a reply',
	'author'      => 'necrotic',
	'guid'        => array('http://k4_bb_url.tld/viewtopic.php?id=25#26',true),
	'pubDate'     => date ( 'r' )
);

foreach ( $post as $info )
{
	$RSS->addItem ( $info );
}

echo $RSS->Go();

?>
Return current item: Syndication Classes