From 3a4570b0fc8b3d6339bef71d17d7701554e0bbf7 Mon Sep 17 00:00:00 2001 From: donncha Date: Fri, 12 Oct 2007 16:21:15 +0000 Subject: Merge with WP 2.3 - testing use only! Move pluggable functions out of wpmu-functions and into pluggable.php, fixes #439 git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@1069 7be80a69-a1ef-0310-a953-fb0f7c49ff36 --- wp-includes/rss.php | 51 +++++++++++++++++++++++++++++++++------------------ 1 file changed, 33 insertions(+), 18 deletions(-) (limited to 'wp-includes/rss.php') diff --git a/wp-includes/rss.php b/wp-includes/rss.php index 72b7bb1..8746767 100644 --- a/wp-includes/rss.php +++ b/wp-includes/rss.php @@ -1,4 +1,6 @@ "; - $rss->items = array_slice($rss->items, 0, $num_items); - foreach ($rss->items as $item ) { - echo "
  • \n"; - echo ""; - echo htmlentities($item['title']); - echo "
    \n"; - echo "
  • \n"; - } - echo ""; - } - else { - echo "an error has occured the feed is probably down, try again later."; +} +endif; + +if ( !function_exists('wp_rss') ) : +function wp_rss( $url, $num_items = -1 ) { + if ( $rss = fetch_rss( $url ) ) { + echo ''; + } else { + _e( 'An error has occurred, which probably means the feed is down. Try again later.' ); } } +endif; +if ( !function_exists('get_rss') ) : function get_rss ($url, $num_items = 5) { // Like get posts, but for RSS $rss = fetch_rss($url); if ( $rss ) { @@ -851,4 +864,6 @@ function get_rss ($url, $num_items = 5) { // Like get posts, but for RSS return false; } } +endif; + ?> -- cgit