Wordpress/wp-feed.php
Ryan Boren b721c5b54f index.php now handles feeds and trackbacks.
git-svn-id: https://develop.svn.wordpress.org/trunk@1376 602fd350-edb4-49c9-b593-d223f7449a82
2004-05-31 23:35:32 +00:00

36 lines
678 B
PHP

<?php
if (! $doing_rss) {
$doing_rss = 1;
require('wp-blog-header.php');
}
// Remove the pad, if present.
$feed = preg_replace('/^_+/', '', $feed);
if ($feed == '' || $feed == 'feed') {
// TODO: Get default feed from options DB.
$feed = 'rss2';
}
if ( (($p != '') && ($p != 'all')) || ($name != '') || ($withcomments == 1) ) {
require('wp-commentsrss2.php');
} else {
switch ($feed) {
case 'atom':
require('wp-atom.php');
break;
case 'rdf':
require('wp-rdf.php');
break;
case 'rss':
require('wp-rss.php');
break;
case 'rss2':
require('wp-rss2.php');
break;
}
}
?>