MDL-19698 importing latest dev version of simplepie, this should fix most PHP5.3...
[moodle.git] / lib / simplepie / simplepie.inc
index 45c33c8..b87cbcd 100644 (file)
@@ -5,7 +5,7 @@
  * A PHP-Based RSS and Atom Feed Framework.
  * Takes the hard work out of managing a complete RSS/Atom solution.
  *
- * Copyright (c) 2004-2009, Ryan Parman and Geoffrey Sneddon
+ * Copyright (c) 2004-2009, Ryan Parman, Geoffrey Sneddon, Ryan McCue, and contributors
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without modification, are
  * POSSIBILITY OF SUCH DAMAGE.
  *
  * @package SimplePie
- * @version 1.2
- * @copyright 2004-2009 Ryan Parman, Geoffrey Sneddon
+ * @version 1.3-dev
+ * @copyright 2004-2009 Ryan Parman, Geoffrey Sneddon, Ryan McCue
  * @author Ryan Parman
  * @author Geoffrey Sneddon
+ * @author Ryan McCue
  * @link http://simplepie.org/ SimplePie
- * @link http://simplepie.org/support/ Please submit all bug reports and feature requests to the SimplePie forums
  * @license http://www.opensource.org/licenses/bsd-license.php BSD License
  * @todo phpDoc comments
  */
@@ -51,12 +51,13 @@ define('SIMPLEPIE_NAME', 'SimplePie');
 /**
  * SimplePie Version
  */
-define('SIMPLEPIE_VERSION', '1.2');
+define('SIMPLEPIE_VERSION', '1.3-dev');
 
 /**
  * SimplePie Build
+ * @todo Hardcode for release (there's no need to have to call SimplePie_Misc::parse_date() only every load of simplepie.inc)
  */
-define('SIMPLEPIE_BUILD', '20090627192103');
+define('SIMPLEPIE_BUILD', gmdate('YmdHis', SimplePie_Misc::parse_date(substr('$Date$', 7, 25)) ? SimplePie_Misc::parse_date(substr('$Date$', 7, 25)) : filemtime(__FILE__)));
 
 /**
  * SimplePie Website URL
@@ -333,10 +334,30 @@ define('SIMPLEPIE_NAMESPACE_GEORSS', 'http://www.georss.org/georss');
 define('SIMPLEPIE_NAMESPACE_MEDIARSS', 'http://search.yahoo.com/mrss/');
 
 /**
- * Wrong Media RSS Namespace
+ * Wrong Media RSS Namespace. Caused by a long-standing typo in the spec.
  */
 define('SIMPLEPIE_NAMESPACE_MEDIARSS_WRONG', 'http://search.yahoo.com/mrss');
 
+/**
+ * Wrong Media RSS Namespace #2. New namespace introduced in Media RSS 1.5.
+ */
+define('SIMPLEPIE_NAMESPACE_MEDIARSS_WRONG2', 'http://video.search.yahoo.com/mrss');
+
+/**
+ * Wrong Media RSS Namespace #3. A possible typo of the Media RSS 1.5 namespace.
+ */
+define('SIMPLEPIE_NAMESPACE_MEDIARSS_WRONG3', 'http://video.search.yahoo.com/mrss/');
+
+/**
+ * Wrong Media RSS Namespace #4. New spec location after the RSS Advisory Board takes it over, but not a valid namespace.
+ */
+define('SIMPLEPIE_NAMESPACE_MEDIARSS_WRONG4', 'http://www.rssboard.org/media-rss');
+
+/**
+ * Wrong Media RSS Namespace #5. A possible typo of the RSS Advisory Board URL.
+ */
+define('SIMPLEPIE_NAMESPACE_MEDIARSS_WRONG5', 'http://www.rssboard.org/media-rss/');
+
 /**
  * iTunes RSS Namespace
  */
@@ -398,55 +419,55 @@ class SimplePie
         * @var array Raw data
         * @access private
         */
-       var $data = array();
+       public $data = array();
 
        /**
         * @var mixed Error string
         * @access private
         */
-       var $error;
+       public $error;
 
        /**
         * @var object Instance of SimplePie_Sanitize (or other class)
         * @see SimplePie::set_sanitize_class()
         * @access private
         */
-       var $sanitize;
+       public $sanitize;
 
        /**
         * @var string SimplePie Useragent
         * @see SimplePie::set_useragent()
         * @access private
         */
-       var $useragent = SIMPLEPIE_USERAGENT;
+       public $useragent = SIMPLEPIE_USERAGENT;
 
        /**
         * @var string Feed URL
         * @see SimplePie::set_feed_url()
         * @access private
         */
-       var $feed_url;
+       public $feed_url;
 
        /**
         * @var object Instance of SimplePie_File to use as a feed
         * @see SimplePie::set_file()
         * @access private
         */
-       var $file;
+       public $file;
 
        /**
         * @var string Raw feed data
         * @see SimplePie::set_raw_data()
         * @access private
         */
-       var $raw_data;
+       public $raw_data;
 
        /**
         * @var int Timeout for fetching remote files
         * @see SimplePie::set_timeout()
         * @access private
         */
-       var $timeout = 10;
+       public $timeout = 10;
 
        /**
         * @var bool Forces fsockopen() to be used for remote files instead
@@ -454,7 +475,7 @@ class SimplePie
         * @see SimplePie::force_fsockopen()
         * @access private
         */
-       var $force_fsockopen = false;
+       public $force_fsockopen = false;
 
        /**
         * @var bool Force the given data/URL to be treated as a feed no matter what
@@ -462,56 +483,56 @@ class SimplePie
         * @see SimplePie::force_feed()
         * @access private
         */
-       var $force_feed = false;
+       public $force_feed = false;
 
        /**
         * @var bool Enable/Disable XML dump
         * @see SimplePie::enable_xml_dump()
         * @access private
         */
-       var $xml_dump = false;
+       public $xml_dump = false;
 
        /**
         * @var bool Enable/Disable Caching
         * @see SimplePie::enable_cache()
         * @access private
         */
-       var $cache = true;
+       public $cache = true;
 
        /**
         * @var int Cache duration (in seconds)
         * @see SimplePie::set_cache_duration()
         * @access private
         */
-       var $cache_duration = 3600;
+       public $cache_duration = 3600;
 
        /**
         * @var int Auto-discovery cache duration (in seconds)
         * @see SimplePie::set_autodiscovery_cache_duration()
         * @access private
         */
-       var $autodiscovery_cache_duration = 604800; // 7 Days.
+       public $autodiscovery_cache_duration = 604800; // 7 Days.
 
        /**
         * @var string Cache location (relative to executing script)
         * @see SimplePie::set_cache_location()
         * @access private
         */
-       var $cache_location = './cache';
+       public $cache_location = './cache';
 
        /**
         * @var string Function that creates the cache filename
         * @see SimplePie::set_cache_name_function()
         * @access private
         */
-       var $cache_name_function = 'md5';
+       public $cache_name_function = 'md5';
 
        /**
         * @var bool Reorder feed by date descending
         * @see SimplePie::enable_order_by_date()
         * @access private
         */
-       var $order_by_date = true;
+       public $order_by_date = true;
 
        /**
         * @var mixed Force input encoding to be set to the follow value
@@ -519,119 +540,119 @@ class SimplePie
         * @see SimplePie::set_input_encoding()
         * @access private
         */
-       var $input_encoding = false;
+       public $input_encoding = false;
 
        /**
         * @var int Feed Autodiscovery Level
         * @see SimplePie::set_autodiscovery_level()
         * @access private
         */
-       var $autodiscovery = SIMPLEPIE_LOCATOR_ALL;
+       public $autodiscovery = SIMPLEPIE_LOCATOR_ALL;
 
        /**
         * @var string Class used for caching feeds
         * @see SimplePie::set_cache_class()
         * @access private
         */
-       var $cache_class = 'SimplePie_Cache';
+       public $cache_class = 'SimplePie_Cache';
 
        /**
         * @var string Class used for locating feeds
         * @see SimplePie::set_locator_class()
         * @access private
         */
-       var $locator_class = 'SimplePie_Locator';
+       public $locator_class = 'SimplePie_Locator';
 
        /**
         * @var string Class used for parsing feeds
         * @see SimplePie::set_parser_class()
         * @access private
         */
-       var $parser_class = 'SimplePie_Parser';
+       public $parser_class = 'SimplePie_Parser';
 
        /**
         * @var string Class used for fetching feeds
         * @see SimplePie::set_file_class()
         * @access private
         */
-       var $file_class = 'SimplePie_File';
+       public $file_class = 'SimplePie_File';
 
        /**
         * @var string Class used for items
         * @see SimplePie::set_item_class()
         * @access private
         */
-       var $item_class = 'SimplePie_Item';
+       public $item_class = 'SimplePie_Item';
 
        /**
         * @var string Class used for authors
         * @see SimplePie::set_author_class()
         * @access private
         */
-       var $author_class = 'SimplePie_Author';
+       public $author_class = 'SimplePie_Author';
 
        /**
         * @var string Class used for categories
         * @see SimplePie::set_category_class()
         * @access private
         */
-       var $category_class = 'SimplePie_Category';
+       public $category_class = 'SimplePie_Category';
 
        /**
         * @var string Class used for enclosures
         * @see SimplePie::set_enclosures_class()
         * @access private
         */
-       var $enclosure_class = 'SimplePie_Enclosure';
+       public $enclosure_class = 'SimplePie_Enclosure';
 
        /**
         * @var string Class used for Media RSS <media:text> captions
         * @see SimplePie::set_caption_class()
         * @access private
         */
-       var $caption_class = 'SimplePie_Caption';
+       public $caption_class = 'SimplePie_Caption';
 
        /**
         * @var string Class used for Media RSS <media:copyright>
         * @see SimplePie::set_copyright_class()
         * @access private
         */
-       var $copyright_class = 'SimplePie_Copyright';
+       public $copyright_class = 'SimplePie_Copyright';
 
        /**
         * @var string Class used for Media RSS <media:credit>
         * @see SimplePie::set_credit_class()
         * @access private
         */
-       var $credit_class = 'SimplePie_Credit';
+       public $credit_class = 'SimplePie_Credit';
 
        /**
         * @var string Class used for Media RSS <media:rating>
         * @see SimplePie::set_rating_class()
         * @access private
         */
-       var $rating_class = 'SimplePie_Rating';
+       public $rating_class = 'SimplePie_Rating';
 
        /**
         * @var string Class used for Media RSS <media:restriction>
         * @see SimplePie::set_restriction_class()
         * @access private
         */
-       var $restriction_class = 'SimplePie_Restriction';
+       public $restriction_class = 'SimplePie_Restriction';
 
        /**
         * @var string Class used for content-type sniffing
         * @see SimplePie::set_content_type_sniffer_class()
         * @access private
         */
-       var $content_type_sniffer_class = 'SimplePie_Content_Type_Sniffer';
+       public $content_type_sniffer_class = 'SimplePie_Content_Type_Sniffer';
 
        /**
         * @var string Class used for item sources.
         * @see SimplePie::set_source_class()
         * @access private
         */
-       var $source_class = 'SimplePie_Source';
+       public $source_class = 'SimplePie_Source';
 
        /**
         * @var mixed Set javascript query string parameter (false, or
@@ -639,76 +660,69 @@ class SimplePie
         * @see SimplePie::set_javascript()
         * @access private
         */
-       var $javascript = 'js';
+       public $javascript = 'js';
 
        /**
         * @var int Maximum number of feeds to check with autodiscovery
         * @see SimplePie::set_max_checked_feeds()
         * @access private
         */
-       var $max_checked_feeds = 10;
+       public $max_checked_feeds = 10;
 
        /**
         * @var array All the feeds found during the autodiscovery process
         * @see SimplePie::get_all_discovered_feeds()
         * @access private
         */
-       var $all_discovered_feeds = array();
-
-       /**
-        * @var string Web-accessible path to the handler_favicon.php file.
-        * @see SimplePie::set_favicon_handler()
-        * @access private
-        */
-       var $favicon_handler = '';
+       public $all_discovered_feeds = array();
 
        /**
         * @var string Web-accessible path to the handler_image.php file.
         * @see SimplePie::set_image_handler()
         * @access private
         */
-       var $image_handler = '';
+       public $image_handler = '';
 
        /**
         * @var array Stores the URLs when multiple feeds are being initialized.
         * @see SimplePie::set_feed_url()
         * @access private
         */
-       var $multifeed_url = array();
+       public $multifeed_url = array();
 
        /**
         * @var array Stores SimplePie objects when multiple feeds initialized.
         * @access private
         */
-       var $multifeed_objects = array();
+       public $multifeed_objects = array();
 
        /**
         * @var array Stores the get_object_vars() array for use with multifeeds.
         * @see SimplePie::set_feed_url()
         * @access private
         */
-       var $config_settings = null;
+       public $config_settings = null;
 
        /**
         * @var integer Stores the number of items to return per-feed with multifeeds.
         * @see SimplePie::set_item_limit()
         * @access private
         */
-       var $item_limit = 0;
+       public $item_limit = 0;
 
        /**
         * @var array Stores the default attributes to be stripped by strip_attributes().
         * @see SimplePie::strip_attributes()
         * @access private
         */
-       var $strip_attributes = array('bgsound', 'class', 'expr', 'id', 'style', 'onclick', 'onerror', 'onfinish', 'onmouseover', 'onmouseout', 'onfocus', 'onblur', 'lowsrc', 'dynsrc');
+       public $strip_attributes = array('bgsound', 'class', 'expr', 'id', 'style', 'onclick', 'onerror', 'onfinish', 'onmouseover', 'onmouseout', 'onfocus', 'onblur', 'lowsrc', 'dynsrc');
 
        /**
         * @var array Stores the default tags to be stripped by strip_htmltags().
         * @see SimplePie::strip_htmltags()
         * @access private
         */
-       var $strip_htmltags = array('base', 'blink', 'body', 'doctype', 'embed', 'font', 'form', 'frame', 'frameset', 'html', 'iframe', 'input', 'marquee', 'meta', 'noscript', 'object', 'param', 'script', 'style');
+       public $strip_htmltags = array('base', 'blink', 'body', 'doctype', 'embed', 'font', 'form', 'frame', 'frameset', 'html', 'iframe', 'input', 'marquee', 'meta', 'noscript', 'object', 'param', 'script', 'style');
 
        /**
         * The SimplePie class contains feed level data and options
@@ -727,38 +741,28 @@ class SimplePie
         *
         * @access public
         * @since 1.0 Preview Release
-        * @param string $feed_url This is the URL you want to parse.
-        * @param string $cache_location This is where you want the cache to be stored.
-        * @param int $cache_duration This is the number of seconds that you want to store the cache file for.
         */
-       function SimplePie($feed_url = null, $cache_location = null, $cache_duration = null)
+       public function __construct()
        {
-               // Other objects, instances created here so we can set options on them
-               $this->sanitize =& new SimplePie_Sanitize;
-
-               // Set options if they're passed to the constructor
-               if ($cache_location !== null)
+               if (version_compare(PHP_VERSION, '5.0', '<'))
                {
-                       $this->set_cache_location($cache_location);
+                       trigger_error('PHP 4.x is no longer supported. Please upgrade to PHP 5.2 or newer.');
+                       die();
                }
 
-               if ($cache_duration !== null)
-               {
-                       $this->set_cache_duration($cache_duration);
-               }
+               // Other objects, instances created here so we can set options on them
+               $this->sanitize = new SimplePie_Sanitize();
 
-               // Only init the script if we're passed a feed URL
-               if ($feed_url !== null)
+               if (func_num_args() > 0)
                {
-                       $this->set_feed_url($feed_url);
-                       $this->init();
+                       trigger_error('Passing parameters to the constructor is no longer supported. Please use set_feed_url(), set_cache_location(), and set_cache_location() directly.');
                }
        }
 
        /**
         * Used for converting object to a string
         */
-       function __toString()
+       public function __toString()
        {
                return md5(serialize($this->data));
        }
@@ -766,7 +770,7 @@ class SimplePie
        /**
         * Remove items that link back to this before destroying this object
         */
-       function __destruct()
+       public function __destruct()
        {
                if ((version_compare(PHP_VERSION, '5.3', '<') || !gc_enabled()) && !ini_get('zend.ze1_compatibility_mode'))
                {
@@ -797,7 +801,7 @@ class SimplePie
         * @since 1.1
         * @param bool $enable Force the given data/URL to be treated as a feed
         */
-       function force_feed($enable = false)
+       public function force_feed($enable = false)
        {
                $this->force_feed = (bool) $enable;
        }
@@ -818,7 +822,7 @@ class SimplePie
         * @param mixed $url This is the URL (or array of URLs) that you want to parse.
         * @see SimplePie::set_raw_data()
         */
-       function set_feed_url($url)
+       public function set_feed_url($url)
        {
                if (is_array($url))
                {
@@ -841,7 +845,7 @@ class SimplePie
         * @param object &$file Instance of SimplePie_File (or subclass)
         * @return bool True on success, false on failure
         */
-       function set_file(&$file)
+       public function set_file(&$file)
        {
                if (is_a($file, 'SimplePie_File'))
                {
@@ -864,7 +868,7 @@ class SimplePie
         * @param string $data RSS or Atom data as a string.
         * @see SimplePie::set_feed_url()
         */
-       function set_raw_data($data)
+       public function set_raw_data($data)
        {
                $this->raw_data = $data;
        }
@@ -879,7 +883,7 @@ class SimplePie
         * @since 1.0 Beta 3
         * @param int $timeout The maximum number of seconds to spend waiting to retrieve a feed.
         */
-       function set_timeout($timeout = 10)
+       public function set_timeout($timeout = 10)
        {
                $this->timeout = (int) $timeout;
        }
@@ -892,31 +896,11 @@ class SimplePie
         * @since 1.0 Beta 3
         * @param bool $enable Force fsockopen() to be used
         */
-       function force_fsockopen($enable = false)
+       public function force_fsockopen($enable = false)
        {
                $this->force_fsockopen = (bool) $enable;
        }
 
-       /**
-        * Outputs the raw XML content of the feed, after it has gone through
-        * SimplePie's filters.
-        *
-        * Used only for debugging, this function will output the XML content as
-        * text/xml. When SimplePie reads in a feed, it does a bit of cleaning up
-        * before trying to parse it. Many parts of the feed are re-written in
-        * memory, and in the end, you have a parsable feed. XML dump shows you the
-        * actual XML that SimplePie tries to parse, which may or may not be very
-        * different from the original feed.
-        *
-        * @access public
-        * @since 1.0 Preview Release
-        * @param bool $enable Enable XML dump
-        */
-       function enable_xml_dump($enable = false)
-       {
-               $this->xml_dump = (bool) $enable;
-       }
-
        /**
         * Enables/disables caching in SimplePie.
         *
@@ -927,7 +911,7 @@ class SimplePie
         * @since 1.0 Preview Release
         * @param bool $enable Enable caching
         */
-       function enable_cache($enable = true)
+       public function enable_cache($enable = true)
        {
                $this->cache = (bool) $enable;
        }
@@ -939,7 +923,7 @@ class SimplePie
         * @access public
         * @param int $seconds The feed content cache duration.
         */
-       function set_cache_duration($seconds = 3600)
+       public function set_cache_duration($seconds = 3600)
        {
                $this->cache_duration = (int) $seconds;
        }
@@ -951,7 +935,7 @@ class SimplePie
         * @access public
         * @param int $seconds The autodiscovered feed URL cache duration.
         */
-       function set_autodiscovery_cache_duration($seconds = 604800)
+       public function set_autodiscovery_cache_duration($seconds = 604800)
        {
                $this->autodiscovery_cache_duration = (int) $seconds;
        }
@@ -962,7 +946,7 @@ class SimplePie
         * @access public
         * @param string $location The file system location.
         */
-       function set_cache_location($location = './cache')
+       public function set_cache_location($location = './cache')
        {
                $this->cache_location = (string) $location;
        }
@@ -973,7 +957,7 @@ class SimplePie
         * @access public
         * @param bool $enable Sort as reverse chronological order.
         */
-       function enable_order_by_date($enable = true)
+       public function enable_order_by_date($enable = true)
        {
                $this->order_by_date = (bool) $enable;
        }
@@ -984,7 +968,7 @@ class SimplePie
         * @access public
         * @param string $encoding Character encoding.
         */
-       function set_input_encoding($encoding = false)
+       public function set_input_encoding($encoding = false)
        {
                if ($encoding)
                {
@@ -1010,7 +994,7 @@ class SimplePie
         * @param int $level Feed Autodiscovery Level (level can be a
         * combination of the above constants, see bitwise OR operator)
         */
-       function set_autodiscovery_level($level = SIMPLEPIE_LOCATOR_ALL)
+       public function set_autodiscovery_level($level = SIMPLEPIE_LOCATOR_ALL)
        {
                $this->autodiscovery = (int) $level;
        }
@@ -1021,10 +1005,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_cache_class($class = 'SimplePie_Cache')
+       public function set_cache_class($class = 'SimplePie_Cache')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Cache'))
                {
@@ -1040,10 +1023,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_locator_class($class = 'SimplePie_Locator')
+       public function set_locator_class($class = 'SimplePie_Locator')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Locator'))
                {
@@ -1059,10 +1041,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_parser_class($class = 'SimplePie_Parser')
+       public function set_parser_class($class = 'SimplePie_Parser')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Parser'))
                {
@@ -1078,10 +1059,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_file_class($class = 'SimplePie_File')
+       public function set_file_class($class = 'SimplePie_File')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_File'))
                {
@@ -1097,14 +1077,13 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_sanitize_class($class = 'SimplePie_Sanitize')
+       public function set_sanitize_class($class = 'SimplePie_Sanitize')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Sanitize'))
                {
-                       $this->sanitize =& new $class;
+                       $this->sanitize = new $class();
                        return true;
                }
                return false;
@@ -1116,10 +1095,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_item_class($class = 'SimplePie_Item')
+       public function set_item_class($class = 'SimplePie_Item')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Item'))
                {
@@ -1135,10 +1113,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_author_class($class = 'SimplePie_Author')
+       public function set_author_class($class = 'SimplePie_Author')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Author'))
                {
@@ -1154,10 +1131,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_category_class($class = 'SimplePie_Category')
+       public function set_category_class($class = 'SimplePie_Category')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Category'))
                {
@@ -1173,10 +1149,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_enclosure_class($class = 'SimplePie_Enclosure')
+       public function set_enclosure_class($class = 'SimplePie_Enclosure')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Enclosure'))
                {
@@ -1192,10 +1167,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_caption_class($class = 'SimplePie_Caption')
+       public function set_caption_class($class = 'SimplePie_Caption')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Caption'))
                {
@@ -1211,10 +1185,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_copyright_class($class = 'SimplePie_Copyright')
+       public function set_copyright_class($class = 'SimplePie_Copyright')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Copyright'))
                {
@@ -1230,10 +1203,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_credit_class($class = 'SimplePie_Credit')
+       public function set_credit_class($class = 'SimplePie_Credit')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Credit'))
                {
@@ -1249,10 +1221,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_rating_class($class = 'SimplePie_Rating')
+       public function set_rating_class($class = 'SimplePie_Rating')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Rating'))
                {
@@ -1268,10 +1239,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_restriction_class($class = 'SimplePie_Restriction')
+       public function set_restriction_class($class = 'SimplePie_Restriction')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Restriction'))
                {
@@ -1287,10 +1257,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_content_type_sniffer_class($class = 'SimplePie_Content_Type_Sniffer')
+       public function set_content_type_sniffer_class($class = 'SimplePie_Content_Type_Sniffer')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Content_Type_Sniffer'))
                {
@@ -1306,10 +1275,9 @@ class SimplePie
         *
         * @access public
         * @param string $class Name of custom class.
-        * @link http://php.net/manual/en/keyword.extends.php PHP4 extends documentation
         * @link http://php.net/manual/en/language.oop5.basic.php#language.oop5.basic.extends PHP5 extends documentation
         */
-       function set_source_class($class = 'SimplePie_Source')
+       public function set_source_class($class = 'SimplePie_Source')
        {
                if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Source'))
                {
@@ -1325,7 +1293,7 @@ class SimplePie
         * @access public
         * @param string $ua New user agent string.
         */
-       function set_useragent($ua = SIMPLEPIE_USERAGENT)
+       public function set_useragent($ua = SIMPLEPIE_USERAGENT)
        {
                $this->useragent = (string) $ua;
        }
@@ -1336,7 +1304,7 @@ class SimplePie
         * @access public
         * @param mixed $function Callback function
         */
-       function set_cache_name_function($function = 'md5')
+       public function set_cache_name_function($function = 'md5')
        {
                if (is_callable($function))
                {
@@ -1350,7 +1318,7 @@ class SimplePie
         * @access public
         * @param mixed $get Javascript query string parameter
         */
-       function set_javascript($get = 'js')
+       public function set_javascript($get = 'js')
        {
                if ($get)
                {
@@ -1369,7 +1337,7 @@ class SimplePie
         * @access public
         * @param bool $set Whether to set them or not
         */
-       function set_stupidly_fast($set = false)
+       public function set_stupidly_fast($set = false)
        {
                if ($set)
                {
@@ -1388,17 +1356,17 @@ class SimplePie
         * @access public
         * @param int $max Maximum number of feeds to check
         */
-       function set_max_checked_feeds($max = 10)
+       public function set_max_checked_feeds($max = 10)
        {
                $this->max_checked_feeds = (int) $max;
        }
 
-       function remove_div($enable = true)
+       public function remove_div($enable = true)
        {
                $this->sanitize->remove_div($enable);
        }
 
-       function strip_htmltags($tags = '', $encode = null)
+       public function strip_htmltags($tags = '', $encode = null)
        {
                if ($tags === '')
                {
@@ -1411,12 +1379,12 @@ class SimplePie
                }
        }
 
-       function encode_instead_of_strip($enable = true)
+       public function encode_instead_of_strip($enable = true)
        {
                $this->sanitize->encode_instead_of_strip($enable);
        }
 
-       function strip_attributes($attribs = '')
+       public function strip_attributes($attribs = '')
        {
                if ($attribs === '')
                {
@@ -1425,12 +1393,12 @@ class SimplePie
                $this->sanitize->strip_attributes($attribs);
        }
 
-       function set_output_encoding($encoding = 'UTF-8')
+       public function set_output_encoding($encoding = 'UTF-8')
        {
                $this->sanitize->set_output_encoding($encoding);
        }
 
-       function strip_comments($strip = false)
+       public function strip_comments($strip = false)
        {
                $this->sanitize->strip_comments($strip);
        }
@@ -1443,30 +1411,11 @@ class SimplePie
         * @since 1.0
         * @param array $element_attribute Element/attribute key/value pairs
         */
-       function set_url_replacements($element_attribute = array('a' => 'href', 'area' => 'href', 'blockquote' => 'cite', 'del' => 'cite', 'form' => 'action', 'img' => array('longdesc', 'src'), 'input' => 'src', 'ins' => 'cite', 'q' => 'cite'))
+       public function set_url_replacements($element_attribute = array('a' => 'href', 'area' => 'href', 'blockquote' => 'cite', 'del' => 'cite', 'form' => 'action', 'img' => array('longdesc', 'src'), 'input' => 'src', 'ins' => 'cite', 'q' => 'cite'))
        {
                $this->sanitize->set_url_replacements($element_attribute);
        }
 
-       /**
-        * Set the handler to enable the display of cached favicons.
-        *
-        * @access public
-        * @param str $page Web-accessible path to the handler_favicon.php file.
-        * @param str $qs The query string that the value should be passed to.
-        */
-       function set_favicon_handler($page = false, $qs = 'i')
-       {
-               if ($page !== false)
-               {
-                       $this->favicon_handler = $page . '?' . $qs . '=';
-               }
-               else
-               {
-                       $this->favicon_handler = '';
-               }
-       }
-
        /**
         * Set the handler to enable the display of cached images.
         *
@@ -1474,7 +1423,7 @@ class SimplePie
         * @param str $page Web-accessible path to the handler_image.php file.
         * @param str $qs The query string that the value should be passed to.
         */
-       function set_image_handler($page = false, $qs = 'i')
+       public function set_image_handler($page = false, $qs = 'i')
        {
                if ($page !== false)
                {
@@ -1492,12 +1441,12 @@ class SimplePie
         * @access public
         * @param integer $limit The maximum number of items to return.
         */
-       function set_item_limit($limit = 0)
+       public function set_item_limit($limit = 0)
        {
                $this->item_limit = (int) $limit;
        }
 
-       function init()
+       public function init()
        {
                // Check absolute bare minimum requirements.
                if ((function_exists('version_compare') && version_compare(PHP_VERSION, '4.3.0', '<')) || !extension_loaded('xml') || !extension_loaded('pcre'))
@@ -1533,6 +1482,7 @@ class SimplePie
 
                if ($this->feed_url !== null || $this->raw_data !== null)
                {
+                       $this->error = null;
                        $this->data = array();
                        $this->multifeed_objects = array();
                        $cache = false;
@@ -1598,7 +1548,9 @@ class SimplePie
                                                                {
                                                                        $headers['if-none-match'] = '"' . $this->data['headers']['etag'] . '"';
                                                                }
-                                                               $file =& new $this->file_class($this->feed_url, $this->timeout/10, 5, $headers, $this->useragent, $this->force_fsockopen);
+
+                                                               $file = new $this->file_class($this->feed_url, $this->timeout/10, 5, $headers, $this->useragent, $this->force_fsockopen);
+
                                                                if ($file->success)
                                                                {
                                                                        if ($file->status_code === 304)
@@ -1639,7 +1591,7 @@ class SimplePie
                                        }
                                        else
                                        {
-                                               $file =& new $this->file_class($this->feed_url, $this->timeout, 5, null, $this->useragent, $this->force_fsockopen);
+                                               $file = new $this->file_class($this->feed_url, $this->timeout, 5, null, $this->useragent, $this->force_fsockopen);
                                        }
                                }
                                // If the file connection has an error, set SimplePie::error to that and quit
@@ -1659,7 +1611,8 @@ class SimplePie
                                if (!$this->force_feed)
                                {
                                        // Check if the supplied URL is a feed, if it isn't, look for it.
-                                       $locate =& new $this->locator_class($file, $this->timeout, $this->useragent, $this->file_class, $this->max_checked_feeds, $this->content_type_sniffer_class);
+                                       $locate = new $this->locator_class($file, $this->timeout, $this->useragent, $this->file_class, $this->max_checked_feeds, $this->content_type_sniffer_class);
+
                                        if (!$locate->is_feed($file))
                                        {
                                                // We need to unset this so that if SimplePie::set_file() has been called that object is untouched
@@ -1671,7 +1624,7 @@ class SimplePie
                                                                $this->data = array('url' => $this->feed_url, 'feed_url' => $file->url, 'build' => SIMPLEPIE_BUILD);
                                                                if (!$cache->save($this))
                                                                {
-                                                                       trigger_error("$this->cache_location is not writeable", E_USER_WARNING);
+                                                                       trigger_error("$this->cache_location is not writeable. Make sure you've set the correct relative or absolute path, and that the location is server-writable.", E_USER_WARNING);
                                                                }
                                                                $cache = call_user_func(array($this->cache_class, 'create'), $this->cache_location, call_user_func($this->cache_name_function, $file->url), 'spc');
                                                        }
@@ -1679,7 +1632,7 @@ class SimplePie
                                                }
                                                else
                                                {
-                                                       $this->error = "A feed could not be found at $this->feed_url";
+                                                       $this->error = "A feed could not be found at $this->feed_url. A feed with an invalid mime type may fall victim to this error, or " . SIMPLEPIE_NAME . " was unable to auto-discover it.. Use force_feed() if you are certain this URL is a real feed.";
                                                        SimplePie_Misc::error($this->error, E_USER_NOTICE, __FILE__, __LINE__);
                                                        return false;
                                                }
@@ -1689,7 +1642,7 @@ class SimplePie
 
                                $headers = $file->headers;
                                $data = $file->body;
-                               $sniffer =& new $this->content_type_sniffer_class($file);
+                               $sniffer = new $this->content_type_sniffer_class($file);
                                $sniffed = $sniffer->get_type();
                        }
                        else
@@ -1759,7 +1712,7 @@ class SimplePie
                                if ($utf8_data = SimplePie_Misc::change_encoding($data, $encoding, 'UTF-8'))
                                {
                                        // Create new parser
-                                       $parser =& new $this->parser_class();
+                                       $parser = new $this->parser_class();
 
                                        // If it's parsed fine
                                        if ($parser->parse($utf8_data, 'UTF-8'))
@@ -1776,29 +1729,32 @@ class SimplePie
                                                        // Cache the file if caching is enabled
                                                        if ($cache && !$cache->save($this))
                                                        {
-                                                               trigger_error("$cache->name is not writeable", E_USER_WARNING);
+                                                               trigger_error("$this->cache_location is not writeable. Make sure you've set the correct relative or absolute path, and that the location is server-writable.", E_USER_WARNING);
                                                        }
                                                        return true;
                                                }
                                                else
                                                {
-                                                       $this->error = "A feed could not be found at $this->feed_url";
+                                                       $this->error = "A feed could not be found at $this->feed_url. This does not appear to be a valid RSS or Atom feed.";
                                                        SimplePie_Misc::error($this->error, E_USER_NOTICE, __FILE__, __LINE__);
                                                        return false;
                                                }
                                        }
                                }
                        }
-                       if(isset($parser))
+
+                       if (isset($parser))
                        {
                                // We have an error, just set SimplePie_Misc::error to it and quit
-                               $this->error = sprintf('XML error: %s at line %d, column %d', $parser->get_error_string(), $parser->get_current_line(), $parser->get_current_column());
+                               $this->error = sprintf('This XML document is invalid, likely due to invalid characters. XML error: %s at line %d, column %d', $parser->get_error_string(), $parser->get_current_line(), $parser->get_current_column());
                        }
                        else
                        {
-                               $this->error = 'The data could not be converted to UTF-8';
+                               $this->error = 'The data could not be converted to UTF-8. You MUST have either the iconv or mbstring extension installed. Upgrading to PHP 5.x (which includes iconv) is highly recommended.';
                        }
+
                        SimplePie_Misc::error($this->error, E_USER_NOTICE, __FILE__, __LINE__);
+
                        return false;
                }
                elseif (!empty($this->multifeed_url))
@@ -1835,17 +1791,17 @@ class SimplePie
         * @access public
         * @return string Error message
         */
-       function error()
+       public function error()
        {
                return $this->error;
        }
 
-       function get_encoding()
+       public function get_encoding()
        {
                return $this->sanitize->output_encoding;
        }
 
-       function handle_content_type($mime = 'text/html')
+       public function handle_content_type($mime = 'text/html')
        {
                if (!headers_sent())
                {
@@ -1862,7 +1818,7 @@ class SimplePie
                }
        }
 
-       function get_type()
+       public function get_type()
        {
                if (!isset($this->data['type']))
                {
@@ -1942,73 +1898,12 @@ class SimplePie
                return $this->data['type'];
        }
 
-       /**
-        * Returns the URL for the favicon of the feed's website.
-        *
-        * @todo Cache atom:icon
-        * @access public
-        * @since 1.0
-        */
-       function get_favicon()
-       {
-               if ($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'icon'))
-               {
-                       return $this->sanitize($return[0]['data'], SIMPLEPIE_CONSTRUCT_IRI, $this->get_base($return[0]));
-               }
-               elseif (($url = $this->get_link()) !== null && preg_match('/^http(s)?:\/\//i', $url))
-               {
-                       $favicon = SimplePie_Misc::absolutize_url('/favicon.ico', $url);
-
-                       if ($this->cache && $this->favicon_handler)
-                       {
-                               $favicon_filename = call_user_func($this->cache_name_function, $favicon);
-                               $cache = call_user_func(array($this->cache_class, 'create'), $this->cache_location, $favicon_filename, 'spi');
-
-                               if ($cache->load())
-                               {
-                                       return $this->sanitize($this->favicon_handler . $favicon_filename, SIMPLEPIE_CONSTRUCT_IRI);
-                               }
-                               else
-                               {
-                                       $file =& new $this->file_class($favicon, $this->timeout / 10, 5, array('X-FORWARDED-FOR' => $_SERVER['REMOTE_ADDR']), $this->useragent, $this->force_fsockopen);
-
-                                       if ($file->success && ($file->method & SIMPLEPIE_FILE_SOURCE_REMOTE === 0 || ($file->status_code === 200 || $file->status_code > 206 && $file->status_code < 300)) && strlen($file->body) > 0)
-                                       {
-                                               $sniffer =& new $this->content_type_sniffer_class($file);
-                                               if (substr($sniffer->get_type(), 0, 6) === 'image/')
-                                               {
-                                                       if ($cache->save(array('headers' => $file->headers, 'body' => $file->body)))
-                                                       {
-                                                               return $this->sanitize($this->favicon_handler . $favicon_filename, SIMPLEPIE_CONSTRUCT_IRI);
-                                                       }
-                                                       else
-                                                       {
-                                                               trigger_error("$cache->name is not writeable", E_USER_WARNING);
-                                                               return $this->sanitize($favicon, SIMPLEPIE_CONSTRUCT_IRI);
-                                                       }
-                                               }
-                                               // not an image
-                                               else
-                                               {
-                                                       return false;
-                                               }
-                                       }
-                               }
-                       }
-                       else
-                       {
-                               return $this->sanitize($favicon, SIMPLEPIE_CONSTRUCT_IRI);
-                       }
-               }
-               return false;
-       }
-
        /**
         * @todo If we have a perm redirect we should return the new URL
         * @todo When we make the above change, let's support <itunes:new-feed-url> as well
         * @todo Also, |atom:link|@rel=self
         */
-       function subscribe_url()
+       public function subscribe_url()
        {
                if ($this->feed_url !== null)
                {
@@ -2020,156 +1915,7 @@ class SimplePie
                }
        }
 
-       function subscribe_feed()
-       {
-               if ($this->feed_url !== null)
-               {
-                       return $this->sanitize(SimplePie_Misc::fix_protocol($this->feed_url, 2), SIMPLEPIE_CONSTRUCT_IRI);
-               }
-               else
-               {
-                       return null;
-               }
-       }
-
-       function subscribe_outlook()
-       {
-               if ($this->feed_url !== null)
-               {
-                       return $this->sanitize('outlook' . SimplePie_Misc::fix_protocol($this->feed_url, 2), SIMPLEPIE_CONSTRUCT_IRI);
-               }
-               else
-               {
-                       return null;
-               }
-       }
-
-       function subscribe_podcast()
-       {
-               if ($this->feed_url !== null)
-               {
-                       return $this->sanitize(SimplePie_Misc::fix_protocol($this->feed_url, 3), SIMPLEPIE_CONSTRUCT_IRI);
-               }
-               else
-               {
-                       return null;
-               }
-       }
-
-       function subscribe_itunes()
-       {
-               if ($this->feed_url !== null)
-               {
-                       return $this->sanitize(SimplePie_Misc::fix_protocol($this->feed_url, 4), SIMPLEPIE_CONSTRUCT_IRI);
-               }
-               else
-               {
-                       return null;
-               }
-       }
-
-       /**
-        * Creates the subscribe_* methods' return data
-        *
-        * @access private
-        * @param string $feed_url String to prefix to the feed URL
-        * @param string $site_url String to prefix to the site URL (and
-        * suffix to the feed URL)
-        * @return mixed URL if feed exists, false otherwise
-        */
-       function subscribe_service($feed_url, $site_url = null)
-       {
-               if ($this->subscribe_url())
-               {
-                       $return = $feed_url . rawurlencode($this->feed_url);
-                       if ($site_url !== null && $this->get_link() !== null)
-                       {
-                               $return .= $site_url . rawurlencode($this->get_link());
-                       }
-                       return $this->sanitize($return, SIMPLEPIE_CONSTRUCT_IRI);
-               }
-               else
-               {
-                       return null;
-               }
-       }
-
-       function subscribe_aol()
-       {
-               return $this->subscribe_service('http://feeds.my.aol.com/add.jsp?url=');
-       }
-
-       function subscribe_bloglines()
-       {
-               return $this->subscribe_service('http://www.bloglines.com/sub/');
-       }
-
-       function subscribe_eskobo()
-       {
-               return $this->subscribe_service('http://www.eskobo.com/?AddToMyPage=');
-       }
-
-       function subscribe_feedfeeds()
-       {
-               return $this->subscribe_service('http://www.feedfeeds.com/add?feed=');
-       }
-
-       function subscribe_feedster()
-       {
-               return $this->subscribe_service('http://www.feedster.com/myfeedster.php?action=addrss&confirm=no&rssurl=');
-       }
-
-       function subscribe_google()
-       {
-               return $this->subscribe_service('http://fusion.google.com/add?feedurl=');
-       }
-
-       function subscribe_gritwire()
-       {
-               return $this->subscribe_service('http://my.gritwire.com/feeds/addExternalFeed.aspx?FeedUrl=');
-       }
-
-       function subscribe_msn()
-       {
-               return $this->subscribe_service('http://my.msn.com/addtomymsn.armx?id=rss&ut=', '&ru=');
-       }
-
-       function subscribe_netvibes()
-       {
-               return $this->subscribe_service('http://www.netvibes.com/subscribe.php?url=');
-       }
-
-       function subscribe_newsburst()
-       {
-               return $this->subscribe_service('http://www.newsburst.com/Source/?add=');
-       }
-
-       function subscribe_newsgator()
-       {
-               return $this->subscribe_service('http://www.newsgator.com/ngs/subscriber/subext.aspx?url=');
-       }
-
-       function subscribe_odeo()
-       {
-               return $this->subscribe_service('http://www.odeo.com/listen/subscribe?feed=');
-       }
-
-       function subscribe_podnova()
-       {
-               return $this->subscribe_service('http://www.podnova.com/index_your_podcasts.srf?action=add&url=');
-       }
-
-       function subscribe_rojo()
-       {
-               return $this->subscribe_service('http://www.rojo.com/add-subscription?resource=');
-       }
-
-       function subscribe_yahoo()
-       {
-               return $this->subscribe_service('http://add.my.yahoo.com/rss?url=');
-       }
-
-       function get_feed_tags($namespace, $tag)
+       public function get_feed_tags($namespace, $tag)
        {
                $type = $this->get_type();
                if ($type & SIMPLEPIE_TYPE_ATOM_10)
@@ -2203,7 +1949,7 @@ class SimplePie
                return null;
        }
 
-       function get_channel_tags($namespace, $tag)
+       public function get_channel_tags($namespace, $tag)
        {
                $type = $this->get_type();
                if ($type & SIMPLEPIE_TYPE_ATOM_ALL)
@@ -2246,7 +1992,7 @@ class SimplePie
                return null;
        }
 
-       function get_image_tags($namespace, $tag)
+       public function get_image_tags($namespace, $tag)
        {
                $type = $this->get_type();
                if ($type & SIMPLEPIE_TYPE_RSS_10)
@@ -2282,7 +2028,7 @@ class SimplePie
                return null;
        }
 
-       function get_base($element = array())
+       public function get_base($element = array())
        {
                if (!($this->get_type() & SIMPLEPIE_TYPE_RSS_SYNDICATION) && !empty($element['xml_base_explicit']) && isset($element['xml_base']))
                {
@@ -2298,12 +2044,12 @@ class SimplePie
                }
        }
 
-       function sanitize($data, $type, $base = '')
+       public function sanitize($data, $type, $base = '')
        {
                return $this->sanitize->sanitize($data, $type, $base);
        }
 
-       function get_title()
+       public function get_title()
        {
                if ($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'title'))
                {
@@ -2339,7 +2085,7 @@ class SimplePie
                }
        }
 
-       function get_category($key = 0)
+       public function get_category($key = 0)
        {
                $categories = $this->get_categories();
                if (isset($categories[$key]))
@@ -2352,7 +2098,7 @@ class SimplePie
                }
        }
 
-       function get_categories()
+       public function get_categories()
        {
                $categories = array();
 
@@ -2373,7 +2119,7 @@ class SimplePie
                        {
                                $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
                        }
-                       $categories[] =& new $this->category_class($term, $scheme, $label);
+                       $categories[] = new $this->category_class($term, $scheme, $label);
                }
                foreach ((array) $this->get_channel_tags(SIMPLEPIE_NAMESPACE_RSS_20, 'category') as $category)
                {
@@ -2388,15 +2134,15 @@ class SimplePie
                        {
                                $scheme = null;
                        }
-                       $categories[] =& new $this->category_class($term, $scheme, null);
+                       $categories[] = new $this->category_class($term, $scheme, null);
                }
                foreach ((array) $this->get_channel_tags(SIMPLEPIE_NAMESPACE_DC_11, 'subject') as $category)
                {
-                       $categories[] =& new $this->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $categories[] = new $this->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
                foreach ((array) $this->get_channel_tags(SIMPLEPIE_NAMESPACE_DC_10, 'subject') as $category)
                {
-                       $categories[] =& new $this->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $categories[] = new $this->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
 
                if (!empty($categories))
@@ -2409,7 +2155,7 @@ class SimplePie
                }
        }
 
-       function get_author($key = 0)
+       public function get_author($key = 0)
        {
                $authors = $this->get_authors();
                if (isset($authors[$key]))
@@ -2422,7 +2168,7 @@ class SimplePie
                }
        }
 
-       function get_authors()
+       public function get_authors()
        {
                $authors = array();
                foreach ((array) $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'author') as $author)
@@ -2444,7 +2190,7 @@ class SimplePie
                        }
                        if ($name !== null || $email !== null || $uri !== null)
                        {
-                               $authors[] =& new $this->author_class($name, $uri, $email);
+                               $authors[] = new $this->author_class($name, $uri, $email);
                        }
                }
                if ($author = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ATOM_03, 'author'))
@@ -2466,20 +2212,20 @@ class SimplePie
                        }
                        if ($name !== null || $email !== null || $url !== null)
                        {
-                               $authors[] =& new $this->author_class($name, $url, $email);
+                               $authors[] = new $this->author_class($name, $url, $email);
                        }
                }
                foreach ((array) $this->get_channel_tags(SIMPLEPIE_NAMESPACE_DC_11, 'creator') as $author)
                {
-                       $authors[] =& new $this->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $authors[] = new $this->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
                foreach ((array) $this->get_channel_tags(SIMPLEPIE_NAMESPACE_DC_10, 'creator') as $author)
                {
-                       $authors[] =& new $this->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $authors[] = new $this->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
                foreach ((array) $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'author') as $author)
                {
-                       $authors[] =& new $this->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $authors[] = new $this->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
 
                if (!empty($authors))
@@ -2492,7 +2238,7 @@ class SimplePie
                }
        }
 
-       function get_contributor($key = 0)
+       public function get_contributor($key = 0)
        {
                $contributors = $this->get_contributors();
                if (isset($contributors[$key]))
@@ -2505,7 +2251,7 @@ class SimplePie
                }
        }
 
-       function get_contributors()
+       public function get_contributors()
        {
                $contributors = array();
                foreach ((array) $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'contributor') as $contributor)
@@ -2527,7 +2273,7 @@ class SimplePie
                        }
                        if ($name !== null || $email !== null || $uri !== null)
                        {
-                               $contributors[] =& new $this->author_class($name, $uri, $email);
+                               $contributors[] = new $this->author_class($name, $uri, $email);
                        }
                }
                foreach ((array) $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ATOM_03, 'contributor') as $contributor)
@@ -2549,7 +2295,7 @@ class SimplePie
                        }
                        if ($name !== null || $email !== null || $url !== null)
                        {
-                               $contributors[] =& new $this->author_class($name, $url, $email);
+                               $contributors[] = new $this->author_class($name, $url, $email);
                        }
                }
 
@@ -2563,7 +2309,7 @@ class SimplePie
                }
        }
 
-       function get_link($key = 0, $rel = 'alternate')
+       public function get_link($key = 0, $rel = 'alternate')
        {
                $links = $this->get_links($rel);
                if (isset($links[$key]))
@@ -2579,12 +2325,12 @@ class SimplePie
        /**
         * Added for parity between the parent-level and the item/entry-level.
         */
-       function get_permalink()
+       public function get_permalink()
        {
                return $this->get_link(0);
        }
 
-       function get_links($rel = 'alternate')
+       public function get_links($rel = 'alternate')
        {
                if (!isset($this->data['links']))
                {
@@ -2658,12 +2404,12 @@ class SimplePie
                }
        }
 
-       function get_all_discovered_feeds()
+       public function get_all_discovered_feeds()
        {
                return $this->all_discovered_feeds;
        }
 
-       function get_description()
+       public function get_description()
        {
                if ($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'subtitle'))
                {
@@ -2707,7 +2453,7 @@ class SimplePie
                }
        }
 
-       function get_copyright()
+       public function get_copyright()
        {
                if ($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'rights'))
                {
@@ -2735,7 +2481,7 @@ class SimplePie
                }
        }
 
-       function get_language()
+       public function get_language()
        {
                if ($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_RSS_20, 'language'))
                {
@@ -2771,13 +2517,14 @@ class SimplePie
                }
        }
 
-       function get_latitude()
+       public function get_latitude()
        {
+
                if ($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_W3C_BASIC_GEO, 'lat'))
                {
                        return (float) $return[0]['data'];
                }
-               elseif (($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', $return[0]['data'], $match))
+               elseif (($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', trim($return[0]['data']), $match))
                {
                        return (float) $match[1];
                }
@@ -2787,7 +2534,7 @@ class SimplePie
                }
        }
 
-       function get_longitude()
+       public function get_longitude()
        {
                if ($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_W3C_BASIC_GEO, 'long'))
                {
@@ -2797,7 +2544,7 @@ class SimplePie
                {
                        return (float) $return[0]['data'];
                }
-               elseif (($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', $return[0]['data'], $match))
+               elseif (($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', trim($return[0]['data']), $match))
                {
                        return (float) $match[2];
                }
@@ -2807,7 +2554,7 @@ class SimplePie
                }
        }
 
-       function get_image_title()
+       public function get_image_title()
        {
                if ($return = $this->get_image_tags(SIMPLEPIE_NAMESPACE_RSS_10, 'title'))
                {
@@ -2835,7 +2582,7 @@ class SimplePie
                }
        }
 
-       function get_image_url()
+       public function get_image_url()
        {
                if ($return = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'image'))
                {
@@ -2867,7 +2614,7 @@ class SimplePie
                }
        }
 
-       function get_image_link()
+       public function get_image_link()
        {
                if ($return = $this->get_image_tags(SIMPLEPIE_NAMESPACE_RSS_10, 'link'))
                {
@@ -2887,7 +2634,7 @@ class SimplePie
                }
        }
 
-       function get_image_width()
+       public function get_image_width()
        {
                if ($return = $this->get_image_tags(SIMPLEPIE_NAMESPACE_RSS_20, 'width'))
                {
@@ -2903,7 +2650,7 @@ class SimplePie
                }
        }
 
-       function get_image_height()
+       public function get_image_height()
        {
                if ($return = $this->get_image_tags(SIMPLEPIE_NAMESPACE_RSS_20, 'height'))
                {
@@ -2919,7 +2666,7 @@ class SimplePie
                }
        }
 
-       function get_item_quantity($max = 0)
+       public function get_item_quantity($max = 0)
        {
                $max = (int) $max;
                $qty = count($this->get_items());
@@ -2933,7 +2680,7 @@ class SimplePie
                }
        }
 
-       function get_item($key = 0)
+       public function get_item($key = 0)
        {
                $items = $this->get_items();
                if (isset($items[$key]))
@@ -2946,7 +2693,7 @@ class SimplePie
                }
        }
 
-       function get_items($start = 0, $end = 0)
+       public function get_items($start = 0, $end = 0)
        {
                if (!isset($this->data['items']))
                {
@@ -2962,7 +2709,7 @@ class SimplePie
                                        $keys = array_keys($items);
                                        foreach ($keys as $key)
                                        {
-                                               $this->data['items'][] =& new $this->item_class($this, $items[$key]);
+                                               $this->data['items'][] = new $this->item_class($this, $items[$key]);
                                        }
                                }
                                if ($items = $this->get_feed_tags(SIMPLEPIE_NAMESPACE_ATOM_03, 'entry'))
@@ -2970,7 +2717,7 @@ class SimplePie
                                        $keys = array_keys($items);
                                        foreach ($keys as $key)
                                        {
-                                               $this->data['items'][] =& new $this->item_class($this, $items[$key]);
+                                               $this->data['items'][] = new $this->item_class($this, $items[$key]);
                                        }
                                }
                                if ($items = $this->get_feed_tags(SIMPLEPIE_NAMESPACE_RSS_10, 'item'))
@@ -2978,7 +2725,7 @@ class SimplePie
                                        $keys = array_keys($items);
                                        foreach ($keys as $key)
                                        {
-                                               $this->data['items'][] =& new $this->item_class($this, $items[$key]);
+                                               $this->data['items'][] = new $this->item_class($this, $items[$key]);
                                        }
                                }
                                if ($items = $this->get_feed_tags(SIMPLEPIE_NAMESPACE_RSS_090, 'item'))
@@ -2986,7 +2733,7 @@ class SimplePie
                                        $keys = array_keys($items);
                                        foreach ($keys as $key)
                                        {
-                                               $this->data['items'][] =& new $this->item_class($this, $items[$key]);
+                                               $this->data['items'][] = new $this->item_class($this, $items[$key]);
                                        }
                                }
                                if ($items = $this->get_channel_tags(SIMPLEPIE_NAMESPACE_RSS_20, 'item'))
@@ -2994,7 +2741,7 @@ class SimplePie
                                        $keys = array_keys($items);
                                        foreach ($keys as $key)
                                        {
-                                               $this->data['items'][] =& new $this->item_class($this, $items[$key]);
+                                               $this->data['items'][] = new $this->item_class($this, $items[$key]);
                                        }
                                }
                        }
@@ -3049,7 +2796,7 @@ class SimplePie
        /**
         * @static
         */
-       function sort_items($a, $b)
+       public function sort_items($a, $b)
        {
                return $a->get_date('U') <= $b->get_date('U');
        }
@@ -3057,7 +2804,7 @@ class SimplePie
        /**
         * @static
         */
-       function merge_items($urls, $start = 0, $end = 0, $limit = 0)
+       public function merge_items($urls, $start = 0, $end = 0, $limit = 0)
        {
                if (is_array($urls) && sizeof($urls) > 0)
                {
@@ -3111,13 +2858,13 @@ class SimplePie_Item
        var $feed;
        var $data = array();
 
-       function SimplePie_Item($feed, $data)
+       public function __construct($feed, $data)
        {
                $this->feed = $feed;
                $this->data = $data;
        }
 
-       function __toString()
+       public function __toString()
        {
                return md5(serialize($this->data));
        }
@@ -3125,7 +2872,7 @@ class SimplePie_Item
        /**
         * Remove items that link back to this before destroying this object
         */
-       function __destruct()
+       public function __destruct()
        {
                if ((version_compare(PHP_VERSION, '5.3', '<') || !gc_enabled()) && !ini_get('zend.ze1_compatibility_mode'))
                {
@@ -3133,7 +2880,7 @@ class SimplePie_Item
                }
        }
 
-       function get_item_tags($namespace, $tag)
+       public function get_item_tags($namespace, $tag)
        {
                if (isset($this->data['child'][$namespace][$tag]))
                {
@@ -3145,22 +2892,22 @@ class SimplePie_Item
                }
        }
 
-       function get_base($element = array())
+       public function get_base($element = array())
        {
                return $this->feed->get_base($element);
        }
 
-       function sanitize($data, $type, $base = '')
+       public function sanitize($data, $type, $base = '')
        {
                return $this->feed->sanitize($data, $type, $base);
        }
 
-       function get_feed()
+       public function get_feed()
        {
                return $this->feed;
        }
 
-       function get_id($hash = false)
+       public function get_id($hash = false)
        {
                if (!$hash)
                {
@@ -3203,7 +2950,7 @@ class SimplePie_Item
                }
        }
 
-       function get_title()
+       public function get_title()
        {
                if (!isset($this->data['title']))
                {
@@ -3243,7 +2990,7 @@ class SimplePie_Item
                return $this->data['title'];
        }
 
-       function get_description($description_only = false)
+       public function get_description($description_only = false)
        {
                if ($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'summary'))
                {
@@ -3287,7 +3034,7 @@ class SimplePie_Item
                }
        }
 
-       function get_content($content_only = false)
+       public function get_content($content_only = false)
        {
                if ($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'content'))
                {
@@ -3311,7 +3058,7 @@ class SimplePie_Item
                }
        }
 
-       function get_category($key = 0)
+       public function get_category($key = 0)
        {
                $categories = $this->get_categories();
                if (isset($categories[$key]))
@@ -3324,7 +3071,7 @@ class SimplePie_Item
                }
        }
 
-       function get_categories()
+       public function get_categories()
        {
                $categories = array();
 
@@ -3345,7 +3092,7 @@ class SimplePie_Item
                        {
                                $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
                        }
-                       $categories[] =& new $this->feed->category_class($term, $scheme, $label);
+                       $categories[] = new $this->feed->category_class($term, $scheme, $label);
                }
                foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_RSS_20, 'category') as $category)
                {
@@ -3360,15 +3107,15 @@ class SimplePie_Item
                        {
                                $scheme = null;
                        }
-                       $categories[] =& new $this->feed->category_class($term, $scheme, null);
+                       $categories[] = new $this->feed->category_class($term, $scheme, null);
                }
                foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_DC_11, 'subject') as $category)
                {
-                       $categories[] =& new $this->feed->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $categories[] = new $this->feed->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
                foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_DC_10, 'subject') as $category)
                {
-                       $categories[] =& new $this->feed->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $categories[] = new $this->feed->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
 
                if (!empty($categories))
@@ -3381,7 +3128,7 @@ class SimplePie_Item
                }
        }
 
-       function get_author($key = 0)
+       public function get_author($key = 0)
        {
                $authors = $this->get_authors();
                if (isset($authors[$key]))
@@ -3394,7 +3141,7 @@ class SimplePie_Item
                }
        }
 
-       function get_contributor($key = 0)
+       public function get_contributor($key = 0)
        {
                $contributors = $this->get_contributors();
                if (isset($contributors[$key]))
@@ -3407,7 +3154,7 @@ class SimplePie_Item
                }
        }
 
-       function get_contributors()
+       public function get_contributors()
        {
                $contributors = array();
                foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'contributor') as $contributor)
@@ -3429,7 +3176,7 @@ class SimplePie_Item
                        }
                        if ($name !== null || $email !== null || $uri !== null)
                        {
-                               $contributors[] =& new $this->feed->author_class($name, $uri, $email);
+                               $contributors[] = new $this->feed->author_class($name, $uri, $email);
                        }
                }
                foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_03, 'contributor') as $contributor)
@@ -3451,7 +3198,7 @@ class SimplePie_Item
                        }
                        if ($name !== null || $email !== null || $url !== null)
                        {
-                               $contributors[] =& new $this->feed->author_class($name, $url, $email);
+                               $contributors[] = new $this->feed->author_class($name, $url, $email);
                        }
                }
 
@@ -3465,7 +3212,7 @@ class SimplePie_Item
                }
        }
 
-       function get_authors()
+       public function get_authors()
        {
                $authors = array();
                foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'author') as $author)
@@ -3487,7 +3234,7 @@ class SimplePie_Item
                        }
                        if ($name !== null || $email !== null || $uri !== null)
                        {
-                               $authors[] =& new $this->feed->author_class($name, $uri, $email);
+                               $authors[] = new $this->feed->author_class($name, $uri, $email);
                        }
                }
                if ($author = $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_03, 'author'))
@@ -3509,24 +3256,24 @@ class SimplePie_Item
                        }
                        if ($name !== null || $email !== null || $url !== null)
                        {
-                               $authors[] =& new $this->feed->author_class($name, $url, $email);
+                               $authors[] = new $this->feed->author_class($name, $url, $email);
                        }
                }
                if ($author = $this->get_item_tags(SIMPLEPIE_NAMESPACE_RSS_20, 'author'))
                {
-                       $authors[] =& new $this->feed->author_class(null, null, $this->sanitize($author[0]['data'], SIMPLEPIE_CONSTRUCT_TEXT));
+                       $authors[] = new $this->feed->author_class(null, null, $this->sanitize($author[0]['data'], SIMPLEPIE_CONSTRUCT_TEXT));
                }
                foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_DC_11, 'creator') as $author)
                {
-                       $authors[] =& new $this->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $authors[] = new $this->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
                foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_DC_10, 'creator') as $author)
                {
-                       $authors[] =& new $this->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $authors[] = new $this->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
                foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'author') as $author)
                {
-                       $authors[] =& new $this->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $authors[] = new $this->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
 
                if (!empty($authors))
@@ -3547,7 +3294,7 @@ class SimplePie_Item
                }
        }
 
-       function get_copyright()
+       public function get_copyright()
        {
                if ($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'rights'))
                {
@@ -3567,7 +3314,7 @@ class SimplePie_Item
                }
        }
 
-       function get_date($date_format = 'j F Y, g:i a')
+       public function get_date($date_format = 'j F Y, g:i a')
        {
                if (!isset($this->data['date']))
                {
@@ -3635,7 +3382,7 @@ class SimplePie_Item
                }
        }
 
-       function get_local_date($date_format = '%c')
+       public function get_local_date($date_format = '%c')
        {
                if (!$date_format)
                {
@@ -3651,7 +3398,7 @@ class SimplePie_Item
                }
        }
 
-       function get_permalink()
+       public function get_permalink()
        {
                $link = $this->get_link();
                $enclosure = $this->get_enclosure(0);
@@ -3669,7 +3416,7 @@ class SimplePie_Item
                }
        }
 
-       function get_link($key = 0, $rel = 'alternate')
+       public function get_link($key = 0, $rel = 'alternate')
        {
                $links = $this->get_links($rel);
                if ($links[$key] !== null)
@@ -3682,7 +3429,7 @@ class SimplePie_Item
                }
        }
 
-       function get_links($rel = 'alternate')
+       public function get_links($rel = 'alternate')
        {
                if (!isset($this->data['links']))
                {
@@ -3759,7 +3506,7 @@ class SimplePie_Item
        /**
         * @todo Add ability to prefer one type of content over another (in a media group).
         */
-       function get_enclosure($key = 0, $prefer = null)
+       public function get_enclosure($key = 0, $prefer = null)
        {
                $enclosures = $this->get_enclosures();
                if (isset($enclosures[$key]))
@@ -3782,7 +3529,7 @@ class SimplePie_Item
         * @todo Add support for end-user defined sorting of enclosures by type/handler (so we can prefer the faster-loading FLV over MP4).
         * @todo If an element exists at a level, but it's value is empty, we should fall back to the value from the parent (if it exists).
         */
-       function get_enclosures()
+       public function get_enclosures()
        {
                if (!isset($this->data['enclosures']))
                {
@@ -3836,7 +3583,7 @@ class SimplePie_Item
                                        {
                                                $caption_text = $this->sanitize($caption['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $captions_parent[] =& new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
+                                       $captions_parent[] = new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
                                }
                        }
                        elseif ($captions = $parent->get_channel_tags(SIMPLEPIE_NAMESPACE_MEDIARSS, 'text'))
@@ -3868,7 +3615,7 @@ class SimplePie_Item
                                        {
                                                $caption_text = $this->sanitize($caption['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $captions_parent[] =& new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
+                                       $captions_parent[] = new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
                                }
                        }
                        if (is_array($captions_parent))
@@ -3898,7 +3645,7 @@ class SimplePie_Item
                                {
                                        $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
                                }
-                               $categories_parent[] =& new $this->feed->category_class($term, $scheme, $label);
+                               $categories_parent[] = new $this->feed->category_class($term, $scheme, $label);
                        }
                        foreach ((array) $parent->get_channel_tags(SIMPLEPIE_NAMESPACE_MEDIARSS, 'category') as $category)
                        {
@@ -3921,7 +3668,7 @@ class SimplePie_Item
                                {
                                        $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
                                }
-                               $categories_parent[] =& new $this->feed->category_class($term, $scheme, $label);
+                               $categories_parent[] = new $this->feed->category_class($term, $scheme, $label);
                        }
                        foreach ((array) $parent->get_channel_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'category') as $category)
                        {
@@ -3932,7 +3679,7 @@ class SimplePie_Item
                                {
                                        $label = $this->sanitize($category['attribs']['']['text'], SIMPLEPIE_CONSTRUCT_TEXT);
                                }
-                               $categories_parent[] =& new $this->feed->category_class($term, $scheme, $label);
+                               $categories_parent[] = new $this->feed->category_class($term, $scheme, $label);
 
                                if (isset($category['child'][SIMPLEPIE_NAMESPACE_ITUNES]['category']))
                                {
@@ -3942,7 +3689,7 @@ class SimplePie_Item
                                                {
                                                        $label = $this->sanitize($subcategory['attribs']['']['text'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                }
-                                               $categories_parent[] =& new $this->feed->category_class($term, $scheme, $label);
+                                               $categories_parent[] = new $this->feed->category_class($term, $scheme, $label);
                                        }
                                }
                        }
@@ -3964,7 +3711,7 @@ class SimplePie_Item
                                {
                                        $copyright_label = $this->sanitize($copyright[0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                }
-                               $copyrights_parent =& new $this->feed->copyright_class($copyright_url, $copyright_label);
+                               $copyrights_parent = new $this->feed->copyright_class($copyright_url, $copyright_label);
                        }
                        elseif ($copyright = $parent->get_channel_tags(SIMPLEPIE_NAMESPACE_MEDIARSS, 'copyright'))
                        {
@@ -3978,7 +3725,7 @@ class SimplePie_Item
                                {
                                        $copyright_label = $this->sanitize($copyright[0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                }
-                               $copyrights_parent =& new $this->feed->copyright_class($copyright_url, $copyright_label);
+                               $copyrights_parent = new $this->feed->copyright_class($copyright_url, $copyright_label);
                        }
 
                        // CREDITS
@@ -4005,7 +3752,7 @@ class SimplePie_Item
                                        {
                                                $credit_name = $this->sanitize($credit['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $credits_parent[] =& new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
+                                       $credits_parent[] = new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
                                }
                        }
                        elseif ($credits = $parent->get_channel_tags(SIMPLEPIE_NAMESPACE_MEDIARSS, 'credit'))
@@ -4031,7 +3778,7 @@ class SimplePie_Item
                                        {
                                                $credit_name = $this->sanitize($credit['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $credits_parent[] =& new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
+                                       $credits_parent[] = new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
                                }
                        }
                        if (is_array($credits_parent))
@@ -4220,7 +3967,7 @@ class SimplePie_Item
                                        {
                                                $rating_value = $this->sanitize($rating['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $ratings_parent[] =& new $this->feed->rating_class($rating_scheme, $rating_value);
+                                       $ratings_parent[] = new $this->feed->rating_class($rating_scheme, $rating_value);
                                }
                        }
                        elseif ($ratings = $this->get_item_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'explicit'))
@@ -4233,7 +3980,7 @@ class SimplePie_Item
                                        {
                                                $rating_value = $this->sanitize($rating['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $ratings_parent[] =& new $this->feed->rating_class($rating_scheme, $rating_value);
+                                       $ratings_parent[] = new $this->feed->rating_class($rating_scheme, $rating_value);
                                }
                        }
                        elseif ($ratings = $parent->get_channel_tags(SIMPLEPIE_NAMESPACE_MEDIARSS, 'rating'))
@@ -4254,7 +4001,7 @@ class SimplePie_Item
                                        {
                                                $rating_value = $this->sanitize($rating['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $ratings_parent[] =& new $this->feed->rating_class($rating_scheme, $rating_value);
+                                       $ratings_parent[] = new $this->feed->rating_class($rating_scheme, $rating_value);
                                }
                        }
                        elseif ($ratings = $parent->get_channel_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'explicit'))
@@ -4267,7 +4014,7 @@ class SimplePie_Item
                                        {
                                                $rating_value = $this->sanitize($rating['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $ratings_parent[] =& new $this->feed->rating_class($rating_scheme, $rating_value);
+                                       $ratings_parent[] = new $this->feed->rating_class($rating_scheme, $rating_value);
                                }
                        }
                        if (is_array($ratings_parent))
@@ -4295,7 +4042,7 @@ class SimplePie_Item
                                        {
                                                $restriction_value = $this->sanitize($restriction['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $restrictions_parent[] =& new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
+                                       $restrictions_parent[] = new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
                                }
                        }
                        elseif ($restrictions = $this->get_item_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'block'))
@@ -4309,7 +4056,7 @@ class SimplePie_Item
                                        {
                                                $restriction_relationship = 'deny';
                                        }
-                                       $restrictions_parent[] =& new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
+                                       $restrictions_parent[] = new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
                                }
                        }
                        elseif ($restrictions = $parent->get_channel_tags(SIMPLEPIE_NAMESPACE_MEDIARSS, 'restriction'))
@@ -4331,7 +4078,7 @@ class SimplePie_Item
                                        {
                                                $restriction_value = $this->sanitize($restriction['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                        }
-                                       $restrictions_parent[] =& new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
+                                       $restrictions_parent[] = new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
                                }
                        }
                        elseif ($restrictions = $parent->get_channel_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'block'))
@@ -4345,7 +4092,7 @@ class SimplePie_Item
                                        {
                                                $restriction_relationship = 'deny';
                                        }
-                                       $restrictions_parent[] =& new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
+                                       $restrictions_parent[] = new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
                                }
                        }
                        if (is_array($restrictions_parent))
@@ -4427,621 +4174,624 @@ class SimplePie_Item
                        // If we have media:group tags, loop through them.
                        foreach ((array) $this->get_item_tags(SIMPLEPIE_NAMESPACE_MEDIARSS, 'group') as $group)
                        {
-                               // If we have media:content tags, loop through them.
-                               foreach ((array) $group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['content'] as $content)
-                               {
-                                       if (isset($content['attribs']['']['url']))
-                                       {
-                                               // Attributes
-                                               $bitrate = null;
-                                               $channels = null;
-                                               $duration = null;
-                                               $expression = null;
-                                               $framerate = null;
-                                               $height = null;
-                                               $javascript = null;
-                                               $lang = null;
-                                               $length = null;
-                                               $medium = null;
-                                               $samplingrate = null;
-                                               $type = null;
-                                               $url = null;
-                                               $width = null;
+                               if(isset($group['child']) && isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['content']))
+                               {
+                                       // If we have media:content tags, loop through them.
+                                       foreach ((array) $group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['content'] as $content)
+                                       {
+                                               if (isset($content['attribs']['']['url']))
+                                               {
+                                                       // Attributes
+                                                       $bitrate = null;
+                                                       $channels = null;
+                                                       $duration = null;
+                                                       $expression = null;
+                                                       $framerate = null;
+                                                       $height = null;
+                                                       $javascript = null;
+                                                       $lang = null;
+                                                       $length = null;
+                                                       $medium = null;
+                                                       $samplingrate = null;
+                                                       $type = null;
+                                                       $url = null;
+                                                       $width = null;
+
+                                                       // Elements
+                                                       $captions = null;
+                                                       $categories = null;
+                                                       $copyrights = null;
+                                                       $credits = null;
+                                                       $description = null;
+                                                       $hashes = null;
+                                                       $keywords = null;
+                                                       $player = null;
+                                                       $ratings = null;
+                                                       $restrictions = null;
+                                                       $thumbnails = null;
+                                                       $title = null;
+
+                                                       // Start checking the attributes of media:content
+                                                       if (isset($content['attribs']['']['bitrate']))
+                                                       {
+                                                               $bitrate = $this->sanitize($content['attribs']['']['bitrate'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       if (isset($content['attribs']['']['channels']))
+                                                       {
+                                                               $channels = $this->sanitize($content['attribs']['']['channels'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       if (isset($content['attribs']['']['duration']))
+                                                       {
+                                                               $duration = $this->sanitize($content['attribs']['']['duration'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       else
+                                                       {
+                                                               $duration = $duration_parent;
+                                                       }
+                                                       if (isset($content['attribs']['']['expression']))
+                                                       {
+                                                               $expression = $this->sanitize($content['attribs']['']['expression'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       if (isset($content['attribs']['']['framerate']))
+                                                       {
+                                                               $framerate = $this->sanitize($content['attribs']['']['framerate'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       if (isset($content['attribs']['']['height']))
+                                                       {
+                                                               $height = $this->sanitize($content['attribs']['']['height'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       if (isset($content['attribs']['']['lang']))
+                                                       {
+                                                               $lang = $this->sanitize($content['attribs']['']['lang'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       if (isset($content['attribs']['']['fileSize']))
+                                                       {
+                                                               $length = ceil($content['attribs']['']['fileSize']);
+                                                       }
+                                                       if (isset($content['attribs']['']['medium']))
+                                                       {
+                                                               $medium = $this->sanitize($content['attribs']['']['medium'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       if (isset($content['attribs']['']['samplingrate']))
+                                                       {
+                                                               $samplingrate = $this->sanitize($content['attribs']['']['samplingrate'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       if (isset($content['attribs']['']['type']))
+                                                       {
+                                                               $type = $this->sanitize($content['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       if (isset($content['attribs']['']['width']))
+                                                       {
+                                                               $width = $this->sanitize($content['attribs']['']['width'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                       }
+                                                       $url = $this->sanitize($content['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
 
-                                               // Elements
-                                               $captions = null;
-                                               $categories = null;
-                                               $copyrights = null;
-                                               $credits = null;
-                                               $description = null;
-                                               $hashes = null;
-                                               $keywords = null;
-                                               $player = null;
-                                               $ratings = null;
-                                               $restrictions = null;
-                                               $thumbnails = null;
-                                               $title = null;
+                                                       // Checking the other optional media: elements. Priority: media:content, media:group, item, channel
 
-                                               // Start checking the attributes of media:content
-                                               if (isset($content['attribs']['']['bitrate']))
-                                               {
-                                                       $bitrate = $this->sanitize($content['attribs']['']['bitrate'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               if (isset($content['attribs']['']['channels']))
-                                               {
-                                                       $channels = $this->sanitize($content['attribs']['']['channels'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               if (isset($content['attribs']['']['duration']))
-                                               {
-                                                       $duration = $this->sanitize($content['attribs']['']['duration'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               else
-                                               {
-                                                       $duration = $duration_parent;
-                                               }
-                                               if (isset($content['attribs']['']['expression']))
-                                               {
-                                                       $expression = $this->sanitize($content['attribs']['']['expression'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               if (isset($content['attribs']['']['framerate']))
-                                               {
-                                                       $framerate = $this->sanitize($content['attribs']['']['framerate'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               if (isset($content['attribs']['']['height']))
-                                               {
-                                                       $height = $this->sanitize($content['attribs']['']['height'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               if (isset($content['attribs']['']['lang']))
-                                               {
-                                                       $lang = $this->sanitize($content['attribs']['']['lang'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               if (isset($content['attribs']['']['fileSize']))
-                                               {
-                                                       $length = ceil($content['attribs']['']['fileSize']);
-                                               }
-                                               if (isset($content['attribs']['']['medium']))
-                                               {
-                                                       $medium = $this->sanitize($content['attribs']['']['medium'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               if (isset($content['attribs']['']['samplingrate']))
-                                               {
-                                                       $samplingrate = $this->sanitize($content['attribs']['']['samplingrate'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               if (isset($content['attribs']['']['type']))
-                                               {
-                                                       $type = $this->sanitize($content['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               if (isset($content['attribs']['']['width']))
-                                               {
-                                                       $width = $this->sanitize($content['attribs']['']['width'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               $url = $this->sanitize($content['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
-
-                                               // Checking the other optional media: elements. Priority: media:content, media:group, item, channel
-
-                                               // CAPTIONS
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['text']))
-                                               {
-                                                       foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['text'] as $caption)
+                                                       // CAPTIONS
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['text']))
                                                        {
-                                                               $caption_type = null;
-                                                               $caption_lang = null;
-                                                               $caption_startTime = null;
-                                                               $caption_endTime = null;
-                                                               $caption_text = null;
-                                                               if (isset($caption['attribs']['']['type']))
-                                                               {
-                                                                       $caption_type = $this->sanitize($caption['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($caption['attribs']['']['lang']))
+                                                               foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['text'] as $caption)
                                                                {
-                                                                       $caption_lang = $this->sanitize($caption['attribs']['']['lang'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($caption['attribs']['']['start']))
-                                                               {
-                                                                       $caption_startTime = $this->sanitize($caption['attribs']['']['start'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($caption['attribs']['']['end']))
-                                                               {
-                                                                       $caption_endTime = $this->sanitize($caption['attribs']['']['end'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $caption_type = null;
+                                                                       $caption_lang = null;
+                                                                       $caption_startTime = null;
+                                                                       $caption_endTime = null;
+                                                                       $caption_text = null;
+                                                                       if (isset($caption['attribs']['']['type']))
+                                                                       {
+                                                                               $caption_type = $this->sanitize($caption['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($caption['attribs']['']['lang']))
+                                                                       {
+                                                                               $caption_lang = $this->sanitize($caption['attribs']['']['lang'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($caption['attribs']['']['start']))
+                                                                       {
+                                                                               $caption_startTime = $this->sanitize($caption['attribs']['']['start'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($caption['attribs']['']['end']))
+                                                                       {
+                                                                               $caption_endTime = $this->sanitize($caption['attribs']['']['end'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($caption['data']))
+                                                                       {
+                                                                               $caption_text = $this->sanitize($caption['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $captions[] = new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
                                                                }
-                                                               if (isset($caption['data']))
+                                                               if (is_array($captions))
                                                                {
-                                                                       $caption_text = $this->sanitize($caption['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $captions = array_values(SimplePie_Misc::array_unique($captions));
                                                                }
-                                                               $captions[] =& new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
                                                        }
-                                                       if (is_array($captions))
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['text']))
                                                        {
-                                                               $captions = array_values(SimplePie_Misc::array_unique($captions));
-                                                       }
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['text']))
-                                               {
-                                                       foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['text'] as $caption)
-                                                       {
-                                                               $caption_type = null;
-                                                               $caption_lang = null;
-                                                               $caption_startTime = null;
-                                                               $caption_endTime = null;
-                                                               $caption_text = null;
-                                                               if (isset($caption['attribs']['']['type']))
-                                                               {
-                                                                       $caption_type = $this->sanitize($caption['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($caption['attribs']['']['lang']))
-                                                               {
-                                                                       $caption_lang = $this->sanitize($caption['attribs']['']['lang'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($caption['attribs']['']['start']))
+                                                               foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['text'] as $caption)
                                                                {
-                                                                       $caption_startTime = $this->sanitize($caption['attribs']['']['start'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($caption['attribs']['']['end']))
-                                                               {
-                                                                       $caption_endTime = $this->sanitize($caption['attribs']['']['end'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $caption_type = null;
+                                                                       $caption_lang = null;
+                                                                       $caption_startTime = null;
+                                                                       $caption_endTime = null;
+                                                                       $caption_text = null;
+                                                                       if (isset($caption['attribs']['']['type']))
+                                                                       {
+                                                                               $caption_type = $this->sanitize($caption['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($caption['attribs']['']['lang']))
+                                                                       {
+                                                                               $caption_lang = $this->sanitize($caption['attribs']['']['lang'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($caption['attribs']['']['start']))
+                                                                       {
+                                                                               $caption_startTime = $this->sanitize($caption['attribs']['']['start'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($caption['attribs']['']['end']))
+                                                                       {
+                                                                               $caption_endTime = $this->sanitize($caption['attribs']['']['end'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($caption['data']))
+                                                                       {
+                                                                               $caption_text = $this->sanitize($caption['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $captions[] = new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
                                                                }
-                                                               if (isset($caption['data']))
+                                                               if (is_array($captions))
                                                                {
-                                                                       $caption_text = $this->sanitize($caption['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $captions = array_values(SimplePie_Misc::array_unique($captions));
                                                                }
-                                                               $captions[] =& new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
                                                        }
-                                                       if (is_array($captions))
+                                                       else
                                                        {
-                                                               $captions = array_values(SimplePie_Misc::array_unique($captions));
+                                                               $captions = $captions_parent;
                                                        }
-                                               }
-                                               else
-                                               {
-                                                       $captions = $captions_parent;
-                                               }
 
-                                               // CATEGORIES
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['category']))
-                                               {
-                                                       foreach ((array) $content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['category'] as $category)
+                                                       // CATEGORIES
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['category']))
                                                        {
-                                                               $term = null;
-                                                               $scheme = null;
-                                                               $label = null;
-                                                               if (isset($category['data']))
-                                                               {
-                                                                       $term = $this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($category['attribs']['']['scheme']))
+                                                               foreach ((array) $content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['category'] as $category)
                                                                {
-                                                                       $scheme = $this->sanitize($category['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               else
-                                                               {
-                                                                       $scheme = 'http://search.yahoo.com/mrss/category_schema';
-                                                               }
-                                                               if (isset($category['attribs']['']['label']))
-                                                               {
-                                                                       $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $term = null;
+                                                                       $scheme = null;
+                                                                       $label = null;
+                                                                       if (isset($category['data']))
+                                                                       {
+                                                                               $term = $this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($category['attribs']['']['scheme']))
+                                                                       {
+                                                                               $scheme = $this->sanitize($category['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       else
+                                                                       {
+                                                                               $scheme = 'http://search.yahoo.com/mrss/category_schema';
+                                                                       }
+                                                                       if (isset($category['attribs']['']['label']))
+                                                                       {
+                                                                               $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $categories[] = new $this->feed->category_class($term, $scheme, $label);
                                                                }
-                                                               $categories[] =& new $this->feed->category_class($term, $scheme, $label);
                                                        }
-                                               }
-                                               if (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['category']))
-                                               {
-                                                       foreach ((array) $group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['category'] as $category)
+                                                       if (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['category']))
                                                        {
-                                                               $term = null;
-                                                               $scheme = null;
-                                                               $label = null;
-                                                               if (isset($category['data']))
-                                                               {
-                                                                       $term = $this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($category['attribs']['']['scheme']))
+                                                               foreach ((array) $group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['category'] as $category)
                                                                {
-                                                                       $scheme = $this->sanitize($category['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               else
-                                                               {
-                                                                       $scheme = 'http://search.yahoo.com/mrss/category_schema';
-                                                               }
-                                                               if (isset($category['attribs']['']['label']))
-                                                               {
-                                                                       $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $term = null;
+                                                                       $scheme = null;
+                                                                       $label = null;
+                                                                       if (isset($category['data']))
+                                                                       {
+                                                                               $term = $this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($category['attribs']['']['scheme']))
+                                                                       {
+                                                                               $scheme = $this->sanitize($category['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       else
+                                                                       {
+                                                                               $scheme = 'http://search.yahoo.com/mrss/category_schema';
+                                                                       }
+                                                                       if (isset($category['attribs']['']['label']))
+                                                                       {
+                                                                               $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $categories[] = new $this->feed->category_class($term, $scheme, $label);
                                                                }
-                                                               $categories[] =& new $this->feed->category_class($term, $scheme, $label);
-                                                       }
-                                               }
-                                               if (is_array($categories) && is_array($categories_parent))
-                                               {
-                                                       $categories = array_values(SimplePie_Misc::array_unique(array_merge($categories, $categories_parent)));
-                                               }
-                                               elseif (is_array($categories))
-                                               {
-                                                       $categories = array_values(SimplePie_Misc::array_unique($categories));
-                                               }
-                                               elseif (is_array($categories_parent))
-                                               {
-                                                       $categories = array_values(SimplePie_Misc::array_unique($categories_parent));
-                                               }
-
-                                               // COPYRIGHTS
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright']))
-                                               {
-                                                       $copyright_url = null;
-                                                       $copyright_label = null;
-                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['attribs']['']['url']))
-                                                       {
-                                                               $copyright_url = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                        }
-                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['data']))
+                                                       if (is_array($categories) && is_array($categories_parent))
                                                        {
-                                                               $copyright_label = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                               $categories = array_values(SimplePie_Misc::array_unique(array_merge($categories, $categories_parent)));
                                                        }
-                                                       $copyrights =& new $this->feed->copyright_class($copyright_url, $copyright_label);
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright']))
-                                               {
-                                                       $copyright_url = null;
-                                                       $copyright_label = null;
-                                                       if (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['attribs']['']['url']))
+                                                       elseif (is_array($categories))
                                                        {
-                                                               $copyright_url = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                               $categories = array_values(SimplePie_Misc::array_unique($categories));
                                                        }
-                                                       if (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['data']))
+                                                       elseif (is_array($categories_parent))
                                                        {
-                                                               $copyright_label = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                               $categories = array_values(SimplePie_Misc::array_unique($categories_parent));
                                                        }
-                                                       $copyrights =& new $this->feed->copyright_class($copyright_url, $copyright_label);
-                                               }
-                                               else
-                                               {
-                                                       $copyrights = $copyrights_parent;
-                                               }
 
-                                               // CREDITS
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['credit']))
-                                               {
-                                                       foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['credit'] as $credit)
+                                                       // COPYRIGHTS
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright']))
                                                        {
-                                                               $credit_role = null;
-                                                               $credit_scheme = null;
-                                                               $credit_name = null;
-                                                               if (isset($credit['attribs']['']['role']))
+                                                               $copyright_url = null;
+                                                               $copyright_label = null;
+                                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['attribs']['']['url']))
                                                                {
-                                                                       $credit_role = $this->sanitize($credit['attribs']['']['role'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $copyright_url = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                                }
-                                                               if (isset($credit['attribs']['']['scheme']))
+                                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['data']))
                                                                {
-                                                                       $credit_scheme = $this->sanitize($credit['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $copyright_label = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                                }
-                                                               else
+                                                               $copyrights = new $this->feed->copyright_class($copyright_url, $copyright_label);
+                                                       }
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright']))
+                                                       {
+                                                               $copyright_url = null;
+                                                               $copyright_label = null;
+                                                               if (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['attribs']['']['url']))
                                                                {
-                                                                       $credit_scheme = 'urn:ebu';
+                                                                       $copyright_url = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                                }
-                                                               if (isset($credit['data']))
+                                                               if (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['data']))
                                                                {
-                                                                       $credit_name = $this->sanitize($credit['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $copyright_label = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                                }
-                                                               $credits[] =& new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
+                                                               $copyrights = new $this->feed->copyright_class($copyright_url, $copyright_label);
                                                        }
-                                                       if (is_array($credits))
+                                                       else
                                                        {
-                                                               $credits = array_values(SimplePie_Misc::array_unique($credits));
+                                                               $copyrights = $copyrights_parent;
                                                        }
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['credit']))
-                                               {
-                                                       foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['credit'] as $credit)
+
+                                                       // CREDITS
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['credit']))
                                                        {
-                                                               $credit_role = null;
-                                                               $credit_scheme = null;
-                                                               $credit_name = null;
-                                                               if (isset($credit['attribs']['']['role']))
+                                                               foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['credit'] as $credit)
                                                                {
-                                                                       $credit_role = $this->sanitize($credit['attribs']['']['role'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $credit_role = null;
+                                                                       $credit_scheme = null;
+                                                                       $credit_name = null;
+                                                                       if (isset($credit['attribs']['']['role']))
+                                                                       {
+                                                                               $credit_role = $this->sanitize($credit['attribs']['']['role'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($credit['attribs']['']['scheme']))
+                                                                       {
+                                                                               $credit_scheme = $this->sanitize($credit['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       else
+                                                                       {
+                                                                               $credit_scheme = 'urn:ebu';
+                                                                       }
+                                                                       if (isset($credit['data']))
+                                                                       {
+                                                                               $credit_name = $this->sanitize($credit['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $credits[] = new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
                                                                }
-                                                               if (isset($credit['attribs']['']['scheme']))
+                                                               if (is_array($credits))
                                                                {
-                                                                       $credit_scheme = $this->sanitize($credit['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $credits = array_values(SimplePie_Misc::array_unique($credits));
                                                                }
-                                                               else
+                                                       }
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['credit']))
+                                                       {
+                                                               foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['credit'] as $credit)
                                                                {
-                                                                       $credit_scheme = 'urn:ebu';
+                                                                       $credit_role = null;
+                                                                       $credit_scheme = null;
+                                                                       $credit_name = null;
+                                                                       if (isset($credit['attribs']['']['role']))
+                                                                       {
+                                                                               $credit_role = $this->sanitize($credit['attribs']['']['role'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($credit['attribs']['']['scheme']))
+                                                                       {
+                                                                               $credit_scheme = $this->sanitize($credit['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       else
+                                                                       {
+                                                                               $credit_scheme = 'urn:ebu';
+                                                                       }
+                                                                       if (isset($credit['data']))
+                                                                       {
+                                                                               $credit_name = $this->sanitize($credit['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $credits[] = new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
                                                                }
-                                                               if (isset($credit['data']))
+                                                               if (is_array($credits))
                                                                {
-                                                                       $credit_name = $this->sanitize($credit['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $credits = array_values(SimplePie_Misc::array_unique($credits));
                                                                }
-                                                               $credits[] =& new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
                                                        }
-                                                       if (is_array($credits))
+                                                       else
                                                        {
-                                                               $credits = array_values(SimplePie_Misc::array_unique($credits));
+                                                               $credits = $credits_parent;
                                                        }
-                                               }
-                                               else
-                                               {
-                                                       $credits = $credits_parent;
-                                               }
-
-                                               // DESCRIPTION
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['description']))
-                                               {
-                                                       $description = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['description'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['description']))
-                                               {
-                                                       $description = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['description'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               else
-                                               {
-                                                       $description = $description_parent;
-                                               }
 
-                                               // HASHES
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['hash']))
-                                               {
-                                                       foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['hash'] as $hash)
+                                                       // DESCRIPTION
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['description']))
                                                        {
-                                                               $value = null;
-                                                               $algo = null;
-                                                               if (isset($hash['data']))
-                                                               {
-                                                                       $value = $this->sanitize($hash['data'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($hash['attribs']['']['algo']))
-                                                               {
-                                                                       $algo = $this->sanitize($hash['attribs']['']['algo'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               else
-                                                               {
-                                                                       $algo = 'md5';
-                                                               }
-                                                               $hashes[] = $algo.':'.$value;
+                                                               $description = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['description'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                        }
-                                                       if (is_array($hashes))
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['description']))
                                                        {
-                                                               $hashes = array_values(SimplePie_Misc::array_unique($hashes));
+                                                               $description = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['description'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                        }
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['hash']))
-                                               {
-                                                       foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['hash'] as $hash)
+                                                       else
                                                        {
-                                                               $value = null;
-                                                               $algo = null;
-                                                               if (isset($hash['data']))
-                                                               {
-                                                                       $value = $this->sanitize($hash['data'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                                               }
-                                                               if (isset($hash['attribs']['']['algo']))
+                                                               $description = $description_parent;
+                                                       }
+
+                                                       // HASHES
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['hash']))
+                                                       {
+                                                               foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['hash'] as $hash)
                                                                {
-                                                                       $algo = $this->sanitize($hash['attribs']['']['algo'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $value = null;
+                                                                       $algo = null;
+                                                                       if (isset($hash['data']))
+                                                                       {
+                                                                               $value = $this->sanitize($hash['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($hash['attribs']['']['algo']))
+                                                                       {
+                                                                               $algo = $this->sanitize($hash['attribs']['']['algo'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       else
+                                                                       {
+                                                                               $algo = 'md5';
+                                                                       }
+                                                                       $hashes[] = $algo.':'.$value;
                                                                }
-                                                               else
+                                                               if (is_array($hashes))
                                                                {
-                                                                       $algo = 'md5';
+                                                                       $hashes = array_values(SimplePie_Misc::array_unique($hashes));
                                                                }
-                                                               $hashes[] = $algo.':'.$value;
-                                                       }
-                                                       if (is_array($hashes))
-                                                       {
-                                                               $hashes = array_values(SimplePie_Misc::array_unique($hashes));
                                                        }
-                                               }
-                                               else
-                                               {
-                                                       $hashes = $hashes_parent;
-                                               }
-
-                                               // KEYWORDS
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords']))
-                                               {
-                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords'][0]['data']))
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['hash']))
                                                        {
-                                                               $temp = explode(',', $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT));
-                                                               foreach ($temp as $word)
+                                                               foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['hash'] as $hash)
                                                                {
-                                                                       $keywords[] = trim($word);
+                                                                       $value = null;
+                                                                       $algo = null;
+                                                                       if (isset($hash['data']))
+                                                                       {
+                                                                               $value = $this->sanitize($hash['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($hash['attribs']['']['algo']))
+                                                                       {
+                                                                               $algo = $this->sanitize($hash['attribs']['']['algo'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       else
+                                                                       {
+                                                                               $algo = 'md5';
+                                                                       }
+                                                                       $hashes[] = $algo.':'.$value;
                                                                }
-                                                               unset($temp);
-                                                       }
-                                                       if (is_array($keywords))
-                                                       {
-                                                               $keywords = array_values(SimplePie_Misc::array_unique($keywords));
-                                                       }
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords']))
-                                               {
-                                                       if (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords'][0]['data']))
-                                                       {
-                                                               $temp = explode(',', $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT));
-                                                               foreach ($temp as $word)
+                                                               if (is_array($hashes))
                                                                {
-                                                                       $keywords[] = trim($word);
+                                                                       $hashes = array_values(SimplePie_Misc::array_unique($hashes));
                                                                }
-                                                               unset($temp);
                                                        }
-                                                       if (is_array($keywords))
+                                                       else
                                                        {
-                                                               $keywords = array_values(SimplePie_Misc::array_unique($keywords));
-                                                       }
-                                               }
-                                               else
-                                               {
-                                                       $keywords = $keywords_parent;
-                                               }
-
-                                               // PLAYER
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['player']))
-                                               {
-                                                       $player = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['player'][0]['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['player']))
-                                               {
-                                                       $player = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['player'][0]['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
-                                               }
-                                               else
-                                               {
-                                                       $player = $player_parent;
-                                               }
-
-                                               // RATINGS
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['rating']))
-                                               {
-                                                       foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['rating'] as $rating)
+                                                               $hashes = $hashes_parent;
+                                                       }
+
+                                                       // KEYWORDS
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords']))
                                                        {
-                                                               $rating_scheme = null;
-                                                               $rating_value = null;
-                                                               if (isset($rating['attribs']['']['scheme']))
+                                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords'][0]['data']))
                                                                {
-                                                                       $rating_scheme = $this->sanitize($rating['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $temp = explode(',', $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT));
+                                                                       foreach ($temp as $word)
+                                                                       {
+                                                                               $keywords[] = trim($word);
+                                                                       }
+                                                                       unset($temp);
                                                                }
-                                                               else
+                                                               if (is_array($keywords))
                                                                {
-                                                                       $rating_scheme = 'urn:simple';
+                                                                       $keywords = array_values(SimplePie_Misc::array_unique($keywords));
                                                                }
-                                                               if (isset($rating['data']))
+                                                       }
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords']))
+                                                       {
+                                                               if (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords'][0]['data']))
                                                                {
-                                                                       $rating_value = $this->sanitize($rating['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $temp = explode(',', $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['keywords'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT));
+                                                                       foreach ($temp as $word)
+                                                                       {
+                                                                               $keywords[] = trim($word);
+                                                                       }
+                                                                       unset($temp);
+                                                               }
+                                                               if (is_array($keywords))
+                                                               {
+                                                                       $keywords = array_values(SimplePie_Misc::array_unique($keywords));
                                                                }
-                                                               $ratings[] =& new $this->feed->rating_class($rating_scheme, $rating_value);
                                                        }
-                                                       if (is_array($ratings))
+                                                       else
                                                        {
-                                                               $ratings = array_values(SimplePie_Misc::array_unique($ratings));
+                                                               $keywords = $keywords_parent;
                                                        }
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['rating']))
-                                               {
-                                                       foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['rating'] as $rating)
+
+                                                       // PLAYER
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['player']))
                                                        {
-                                                               $rating_scheme = null;
-                                                               $rating_value = null;
-                                                               if (isset($rating['attribs']['']['scheme']))
+                                                               $player = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['player'][0]['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
+                                                       }
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['player']))
+                                                       {
+                                                               $player = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['player'][0]['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
+                                                       }
+                                                       else
+                                                       {
+                                                               $player = $player_parent;
+                                                       }
+
+                                                       // RATINGS
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['rating']))
+                                                       {
+                                                               foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['rating'] as $rating)
                                                                {
-                                                                       $rating_scheme = $this->sanitize($rating['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $rating_scheme = null;
+                                                                       $rating_value = null;
+                                                                       if (isset($rating['attribs']['']['scheme']))
+                                                                       {
+                                                                               $rating_scheme = $this->sanitize($rating['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       else
+                                                                       {
+                                                                               $rating_scheme = 'urn:simple';
+                                                                       }
+                                                                       if (isset($rating['data']))
+                                                                       {
+                                                                               $rating_value = $this->sanitize($rating['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $ratings[] = new $this->feed->rating_class($rating_scheme, $rating_value);
                                                                }
-                                                               else
+                                                               if (is_array($ratings))
                                                                {
-                                                                       $rating_scheme = 'urn:simple';
+                                                                       $ratings = array_values(SimplePie_Misc::array_unique($ratings));
                                                                }
-                                                               if (isset($rating['data']))
+                                                       }
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['rating']))
+                                                       {
+                                                               foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['rating'] as $rating)
                                                                {
-                                                                       $rating_value = $this->sanitize($rating['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $rating_scheme = null;
+                                                                       $rating_value = null;
+                                                                       if (isset($rating['attribs']['']['scheme']))
+                                                                       {
+                                                                               $rating_scheme = $this->sanitize($rating['attribs']['']['scheme'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       else
+                                                                       {
+                                                                               $rating_scheme = 'urn:simple';
+                                                                       }
+                                                                       if (isset($rating['data']))
+                                                                       {
+                                                                               $rating_value = $this->sanitize($rating['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $ratings[] = new $this->feed->rating_class($rating_scheme, $rating_value);
+                                                               }
+                                                               if (is_array($ratings))
+                                                               {
+                                                                       $ratings = array_values(SimplePie_Misc::array_unique($ratings));
                                                                }
-                                                               $ratings[] =& new $this->feed->rating_class($rating_scheme, $rating_value);
                                                        }
-                                                       if (is_array($ratings))
+                                                       else
                                                        {
-                                                               $ratings = array_values(SimplePie_Misc::array_unique($ratings));
+                                                               $ratings = $ratings_parent;
                                                        }
-                                               }
-                                               else
-                                               {
-                                                       $ratings = $ratings_parent;
-                                               }
 
-                                               // RESTRICTIONS
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['restriction']))
-                                               {
-                                                       foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['restriction'] as $restriction)
+                                                       // RESTRICTIONS
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['restriction']))
                                                        {
-                                                               $restriction_relationship = null;
-                                                               $restriction_type = null;
-                                                               $restriction_value = null;
-                                                               if (isset($restriction['attribs']['']['relationship']))
+                                                               foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['restriction'] as $restriction)
                                                                {
-                                                                       $restriction_relationship = $this->sanitize($restriction['attribs']['']['relationship'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $restriction_relationship = null;
+                                                                       $restriction_type = null;
+                                                                       $restriction_value = null;
+                                                                       if (isset($restriction['attribs']['']['relationship']))
+                                                                       {
+                                                                               $restriction_relationship = $this->sanitize($restriction['attribs']['']['relationship'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($restriction['attribs']['']['type']))
+                                                                       {
+                                                                               $restriction_type = $this->sanitize($restriction['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($restriction['data']))
+                                                                       {
+                                                                               $restriction_value = $this->sanitize($restriction['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $restrictions[] = new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
                                                                }
-                                                               if (isset($restriction['attribs']['']['type']))
+                                                               if (is_array($restrictions))
                                                                {
-                                                                       $restriction_type = $this->sanitize($restriction['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $restrictions = array_values(SimplePie_Misc::array_unique($restrictions));
                                                                }
-                                                               if (isset($restriction['data']))
+                                                       }
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['restriction']))
+                                                       {
+                                                               foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['restriction'] as $restriction)
                                                                {
-                                                                       $restriction_value = $this->sanitize($restriction['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $restriction_relationship = null;
+                                                                       $restriction_type = null;
+                                                                       $restriction_value = null;
+                                                                       if (isset($restriction['attribs']['']['relationship']))
+                                                                       {
+                                                                               $restriction_relationship = $this->sanitize($restriction['attribs']['']['relationship'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($restriction['attribs']['']['type']))
+                                                                       {
+                                                                               $restriction_type = $this->sanitize($restriction['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       if (isset($restriction['data']))
+                                                                       {
+                                                                               $restriction_value = $this->sanitize($restriction['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       }
+                                                                       $restrictions[] = new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
+                                                               }
+                                                               if (is_array($restrictions))
+                                                               {
+                                                                       $restrictions = array_values(SimplePie_Misc::array_unique($restrictions));
                                                                }
-                                                               $restrictions[] =& new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
                                                        }
-                                                       if (is_array($restrictions))
+                                                       else
                                                        {
-                                                               $restrictions = array_values(SimplePie_Misc::array_unique($restrictions));
+                                                               $restrictions = $restrictions_parent;
                                                        }
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['restriction']))
-                                               {
-                                                       foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['restriction'] as $restriction)
+
+                                                       // THUMBNAILS
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['thumbnail']))
                                                        {
-                                                               $restriction_relationship = null;
-                                                               $restriction_type = null;
-                                                               $restriction_value = null;
-                                                               if (isset($restriction['attribs']['']['relationship']))
+                                                               foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['thumbnail'] as $thumbnail)
                                                                {
-                                                                       $restriction_relationship = $this->sanitize($restriction['attribs']['']['relationship'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $thumbnails[] = $this->sanitize($thumbnail['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
                                                                }
-                                                               if (isset($restriction['attribs']['']['type']))
+                                                               if (is_array($thumbnails))
                                                                {
-                                                                       $restriction_type = $this->sanitize($restriction['attribs']['']['type'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $thumbnails = array_values(SimplePie_Misc::array_unique($thumbnails));
                                                                }
-                                                               if (isset($restriction['data']))
+                                                       }
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['thumbnail']))
+                                                       {
+                                                               foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['thumbnail'] as $thumbnail)
                                                                {
-                                                                       $restriction_value = $this->sanitize($restriction['data'], SIMPLEPIE_CONSTRUCT_TEXT);
+                                                                       $thumbnails[] = $this->sanitize($thumbnail['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
+                                                               }
+                                                               if (is_array($thumbnails))
+                                                               {
+                                                                       $thumbnails = array_values(SimplePie_Misc::array_unique($thumbnails));
                                                                }
-                                                               $restrictions[] =& new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
                                                        }
-                                                       if (is_array($restrictions))
+                                                       else
                                                        {
-                                                               $restrictions = array_values(SimplePie_Misc::array_unique($restrictions));
+                                                               $thumbnails = $thumbnails_parent;
                                                        }
-                                               }
-                                               else
-                                               {
-                                                       $restrictions = $restrictions_parent;
-                                               }
 
-                                               // THUMBNAILS
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['thumbnail']))
-                                               {
-                                                       foreach ($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['thumbnail'] as $thumbnail)
-                                                       {
-                                                               $thumbnails[] = $this->sanitize($thumbnail['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
-                                                       }
-                                                       if (is_array($thumbnails))
+                                                       // TITLES
+                                                       if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['title']))
                                                        {
-                                                               $thumbnails = array_values(SimplePie_Misc::array_unique($thumbnails));
+                                                               $title = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['title'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                        }
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['thumbnail']))
-                                               {
-                                                       foreach ($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['thumbnail'] as $thumbnail)
+                                                       elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['title']))
                                                        {
-                                                               $thumbnails[] = $this->sanitize($thumbnail['attribs']['']['url'], SIMPLEPIE_CONSTRUCT_IRI);
+                                                               $title = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['title'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                        }
-                                                       if (is_array($thumbnails))
+                                                       else
                                                        {
-                                                               $thumbnails = array_values(SimplePie_Misc::array_unique($thumbnails));
+                                                               $title = $title_parent;
                                                        }
-                                               }
-                                               else
-                                               {
-                                                       $thumbnails = $thumbnails_parent;
-                                               }
 
-                                               // TITLES
-                                               if (isset($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['title']))
-                                               {
-                                                       $title = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['title'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['title']))
-                                               {
-                                                       $title = $this->sanitize($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['title'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
-                                               }
-                                               else
-                                               {
-                                                       $title = $title_parent;
+                                                       $this->data['enclosures'][] = new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions, $categories, $channels, $copyrights, $credits, $description, $duration, $expression, $framerate, $hashes, $height, $keywords, $lang, $medium, $player, $ratings, $restrictions, $samplingrate, $thumbnails, $title, $width);
                                                }
-
-                                               $this->data['enclosures'][] =& new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions, $categories, $channels, $copyrights, $credits, $description, $duration, $expression, $framerate, $hashes, $height, $keywords, $lang, $medium, $player, $ratings, $restrictions, $samplingrate, $thumbnails, $title, $width);
                                        }
                                }
                        }
@@ -5170,7 +4920,7 @@ class SimplePie_Item
                                                                {
                                                                        $caption_text = $this->sanitize($caption['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                                }
-                                                               $captions[] =& new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
+                                                               $captions[] = new $this->feed->caption_class($caption_type, $caption_lang, $caption_startTime, $caption_endTime, $caption_text);
                                                        }
                                                        if (is_array($captions))
                                                        {
@@ -5206,7 +4956,7 @@ class SimplePie_Item
                                                                {
                                                                        $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                                }
-                                                               $categories[] =& new $this->feed->category_class($term, $scheme, $label);
+                                                               $categories[] = new $this->feed->category_class($term, $scheme, $label);
                                                        }
                                                }
                                                if (is_array($categories) && is_array($categories_parent))
@@ -5239,7 +4989,7 @@ class SimplePie_Item
                                                        {
                                                                $copyright_label = $this->sanitize($content['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'][0]['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                        }
-                                                       $copyrights =& new $this->feed->copyright_class($copyright_url, $copyright_label);
+                                                       $copyrights = new $this->feed->copyright_class($copyright_url, $copyright_label);
                                                }
                                                else
                                                {
@@ -5270,7 +5020,7 @@ class SimplePie_Item
                                                                {
                                                                        $credit_name = $this->sanitize($credit['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                                }
-                                                               $credits[] =& new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
+                                                               $credits[] = new $this->feed->credit_class($credit_role, $credit_scheme, $credit_name);
                                                        }
                                                        if (is_array($credits))
                                                        {
@@ -5374,7 +5124,7 @@ class SimplePie_Item
                                                                {
                                                                        $rating_value = $this->sanitize($rating['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                                }
-                                                               $ratings[] =& new $this->feed->rating_class($rating_scheme, $rating_value);
+                                                               $ratings[] = new $this->feed->rating_class($rating_scheme, $rating_value);
                                                        }
                                                        if (is_array($ratings))
                                                        {
@@ -5406,7 +5156,7 @@ class SimplePie_Item
                                                                {
                                                                        $restriction_value = $this->sanitize($restriction['data'], SIMPLEPIE_CONSTRUCT_TEXT);
                                                                }
-                                                               $restrictions[] =& new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
+                                                               $restrictions[] = new $this->feed->restriction_class($restriction_relationship, $restriction_type, $restriction_value);
                                                        }
                                                        if (is_array($restrictions))
                                                        {
@@ -5445,7 +5195,7 @@ class SimplePie_Item
                                                        $title = $title_parent;
                                                }
 
-                                               $this->data['enclosures'][] =& new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions, $categories, $channels, $copyrights, $credits, $description, $duration, $expression, $framerate, $hashes, $height, $keywords, $lang, $medium, $player, $ratings, $restrictions, $samplingrate, $thumbnails, $title, $width);
+                                               $this->data['enclosures'][] = new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions, $categories, $channels, $copyrights, $credits, $description, $duration, $expression, $framerate, $hashes, $height, $keywords, $lang, $medium, $player, $ratings, $restrictions, $samplingrate, $thumbnails, $title, $width);
                                        }
                                }
                        }
@@ -5481,7 +5231,7 @@ class SimplePie_Item
                                        }
 
                                        // Since we don't have group or content for these, we'll just pass the '*_parent' variables directly to the constructor
-                                       $this->data['enclosures'][] =& new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions_parent, $categories_parent, $channels, $copyrights_parent, $credits_parent, $description_parent, $duration_parent, $expression, $framerate, $hashes_parent, $height, $keywords_parent, $lang, $medium, $player_parent, $ratings_parent, $restrictions_parent, $samplingrate, $thumbnails_parent, $title_parent, $width);
+                                       $this->data['enclosures'][] = new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions_parent, $categories_parent, $channels, $copyrights_parent, $credits_parent, $description_parent, $duration_parent, $expression, $framerate, $hashes_parent, $height, $keywords_parent, $lang, $medium, $player_parent, $ratings_parent, $restrictions_parent, $samplingrate, $thumbnails_parent, $title_parent, $width);
                                }
                        }
 
@@ -5516,7 +5266,7 @@ class SimplePie_Item
                                        }
 
                                        // Since we don't have group or content for these, we'll just pass the '*_parent' variables directly to the constructor
-                                       $this->data['enclosures'][] =& new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions_parent, $categories_parent, $channels, $copyrights_parent, $credits_parent, $description_parent, $duration_parent, $expression, $framerate, $hashes_parent, $height, $keywords_parent, $lang, $medium, $player_parent, $ratings_parent, $restrictions_parent, $samplingrate, $thumbnails_parent, $title_parent, $width);
+                                       $this->data['enclosures'][] = new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions_parent, $categories_parent, $channels, $copyrights_parent, $credits_parent, $description_parent, $duration_parent, $expression, $framerate, $hashes_parent, $height, $keywords_parent, $lang, $medium, $player_parent, $ratings_parent, $restrictions_parent, $samplingrate, $thumbnails_parent, $title_parent, $width);
                                }
                        }
 
@@ -5551,14 +5301,14 @@ class SimplePie_Item
                                        }
 
                                        // Since we don't have group or content for these, we'll just pass the '*_parent' variables directly to the constructor
-                                       $this->data['enclosures'][] =& new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions_parent, $categories_parent, $channels, $copyrights_parent, $credits_parent, $description_parent, $duration_parent, $expression, $framerate, $hashes_parent, $height, $keywords_parent, $lang, $medium, $player_parent, $ratings_parent, $restrictions_parent, $samplingrate, $thumbnails_parent, $title_parent, $width);
+                                       $this->data['enclosures'][] = new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions_parent, $categories_parent, $channels, $copyrights_parent, $credits_parent, $description_parent, $duration_parent, $expression, $framerate, $hashes_parent, $height, $keywords_parent, $lang, $medium, $player_parent, $ratings_parent, $restrictions_parent, $samplingrate, $thumbnails_parent, $title_parent, $width);
                                }
                        }
 
                        if (sizeof($this->data['enclosures']) === 0 && ($url || $type || $length || $bitrate || $captions_parent || $categories_parent || $channels || $copyrights_parent || $credits_parent || $description_parent || $duration_parent || $expression || $framerate || $hashes_parent || $height || $keywords_parent || $lang || $medium || $player_parent || $ratings_parent || $restrictions_parent || $samplingrate || $thumbnails_parent || $title_parent || $width))
                        {
                                // Since we don't have group or content for these, we'll just pass the '*_parent' variables directly to the constructor
-                               $this->data['enclosures'][] =& new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions_parent, $categories_parent, $channels, $copyrights_parent, $credits_parent, $description_parent, $duration_parent, $expression, $framerate, $hashes_parent, $height, $keywords_parent, $lang, $medium, $player_parent, $ratings_parent, $restrictions_parent, $samplingrate, $thumbnails_parent, $title_parent, $width);
+                               $this->data['enclosures'][] = new $this->feed->enclosure_class($url, $type, $length, $this->feed->javascript, $bitrate, $captions_parent, $categories_parent, $channels, $copyrights_parent, $credits_parent, $description_parent, $duration_parent, $expression, $framerate, $hashes_parent, $height, $keywords_parent, $lang, $medium, $player_parent, $ratings_parent, $restrictions_parent, $samplingrate, $thumbnails_parent, $title_parent, $width);
                        }
 
                        $this->data['enclosures'] = array_values(SimplePie_Misc::array_unique($this->data['enclosures']));
@@ -5573,13 +5323,13 @@ class SimplePie_Item
                }
        }
 
-       function get_latitude()
+       public function get_latitude()
        {
                if ($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_W3C_BASIC_GEO, 'lat'))
                {
                        return (float) $return[0]['data'];
                }
-               elseif (($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', $return[0]['data'], $match))
+               elseif (($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', trim($return[0]['data']), $match))
                {
                        return (float) $match[1];
                }
@@ -5589,7 +5339,7 @@ class SimplePie_Item
                }
        }
 
-       function get_longitude()
+       public function get_longitude()
        {
                if ($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_W3C_BASIC_GEO, 'long'))
                {
@@ -5599,7 +5349,7 @@ class SimplePie_Item
                {
                        return (float) $return[0]['data'];
                }
-               elseif (($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', $return[0]['data'], $match))
+               elseif (($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', trim($return[0]['data']), $match))
                {
                        return (float) $match[2];
                }
@@ -5609,7 +5359,7 @@ class SimplePie_Item
                }
        }
 
-       function get_source()
+       public function get_source()
        {
                if ($return = $this->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'source'))
                {
@@ -5620,106 +5370,6 @@ class SimplePie_Item
                        return null;
                }
        }
-
-       /**
-        * Creates the add_to_* methods' return data
-        *
-        * @access private
-        * @param string $item_url String to prefix to the item permalink
-        * @param string $title_url String to prefix to the item title
-        * (and suffix to the item permalink)
-        * @return mixed URL if feed exists, false otherwise
-        */
-       function add_to_service($item_url, $title_url = null, $summary_url = null)
-       {
-               if ($this->get_permalink() !== null)
-               {
-                       $return = $item_url . rawurlencode($this->get_permalink());
-                       if ($title_url !== null && $this->get_title() !== null)
-                       {
-                               $return .= $title_url . rawurlencode($this->get_title());
-                       }
-                       if ($summary_url !== null && $this->get_description() !== null)
-                       {
-                               $return .= $summary_url . rawurlencode($this->get_description());
-                       }
-                       return $this->sanitize($return, SIMPLEPIE_CONSTRUCT_IRI);
-               }
-               else
-               {
-                       return null;
-               }
-       }
-
-       function add_to_blinklist()
-       {
-               return $this->add_to_service('http://www.blinklist.com/index.php?Action=Blink/addblink.php&Description=&Url=', '&Title=');
-       }
-
-       function add_to_blogmarks()
-       {
-               return $this->add_to_service('http://blogmarks.net/my/new.php?mini=1&simple=1&url=', '&title=');
-       }
-
-       function add_to_delicious()
-       {
-               return $this->add_to_service('http://del.icio.us/post/?v=4&url=', '&title=');
-       }
-
-       function add_to_digg()
-       {
-               return $this->add_to_service('http://digg.com/submit?url=', '&title=', '&bodytext=');
-       }
-
-       function add_to_furl()
-       {
-               return $this->add_to_service('http://www.furl.net/storeIt.jsp?u=', '&t=');
-       }
-
-       function add_to_magnolia()
-       {
-               return $this->add_to_service('http://ma.gnolia.com/bookmarklet/add?url=', '&title=');
-       }
-
-       function add_to_myweb20()
-       {
-               return $this->add_to_service('http://myweb2.search.yahoo.com/myresults/bookmarklet?u=', '&t=');
-       }
-
-       function add_to_newsvine()
-       {
-               return $this->add_to_service('http://www.newsvine.com/_wine/save?u=', '&h=');
-       }
-
-       function add_to_reddit()
-       {
-               return $this->add_to_service('http://reddit.com/submit?url=', '&title=');
-       }
-
-       function add_to_segnalo()
-       {
-               return $this->add_to_service('http://segnalo.com/post.html.php?url=', '&title=');
-       }
-
-       function add_to_simpy()
-       {
-               return $this->add_to_service('http://www.simpy.com/simpy/LinkAdd.do?href=', '&title=');
-       }
-
-       function add_to_spurl()
-       {
-               return $this->add_to_service('http://www.spurl.net/spurl.php?v=3&url=', '&title=');
-       }
-
-       function add_to_wists()
-       {
-               return $this->add_to_service('http://wists.com/r.php?c=&r=', '&title=');
-       }
-
-       function search_technorati()
-       {
-               return $this->add_to_service('http://www.technorati.com/search/');
-       }
 }
 
 class SimplePie_Source
@@ -5727,18 +5377,18 @@ class SimplePie_Source
        var $item;
        var $data = array();
 
-       function SimplePie_Source($item, $data)
+       public function __construct($item, $data)
        {
                $this->item = $item;
                $this->data = $data;
        }
 
-       function __toString()
+       public function __toString()
        {
                return md5(serialize($this->data));
        }
 
-       function get_source_tags($namespace, $tag)
+       public function get_source_tags($namespace, $tag)
        {
                if (isset($this->data['child'][$namespace][$tag]))
                {
@@ -5750,22 +5400,22 @@ class SimplePie_Source
                }
        }
 
-       function get_base($element = array())
+       public function get_base($element = array())
        {
                return $this->item->get_base($element);
        }
 
-       function sanitize($data, $type, $base = '')
+       public function sanitize($data, $type, $base = '')
        {
                return $this->item->sanitize($data, $type, $base);
        }
 
-       function get_item()
+       public function get_item()
        {
                return $this->item;
        }
 
-       function get_title()
+       public function get_title()
        {
                if ($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'title'))
                {
@@ -5801,7 +5451,7 @@ class SimplePie_Source
                }
        }
 
-       function get_category($key = 0)
+       public function get_category($key = 0)
        {
                $categories = $this->get_categories();
                if (isset($categories[$key]))
@@ -5814,7 +5464,7 @@ class SimplePie_Source
                }
        }
 
-       function get_categories()
+       public function get_categories()
        {
                $categories = array();
 
@@ -5835,7 +5485,7 @@ class SimplePie_Source
                        {
                                $label = $this->sanitize($category['attribs']['']['label'], SIMPLEPIE_CONSTRUCT_TEXT);
                        }
-                       $categories[] =& new $this->item->feed->category_class($term, $scheme, $label);
+                       $categories[] = new $this->item->feed->category_class($term, $scheme, $label);
                }
                foreach ((array) $this->get_source_tags(SIMPLEPIE_NAMESPACE_RSS_20, 'category') as $category)
                {
@@ -5850,15 +5500,15 @@ class SimplePie_Source
                        {
                                $scheme = null;
                        }
-                       $categories[] =& new $this->item->feed->category_class($term, $scheme, null);
+                       $categories[] = new $this->item->feed->category_class($term, $scheme, null);
                }
                foreach ((array) $this->get_source_tags(SIMPLEPIE_NAMESPACE_DC_11, 'subject') as $category)
                {
-                       $categories[] =& new $this->item->feed->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $categories[] = new $this->item->feed->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
                foreach ((array) $this->get_source_tags(SIMPLEPIE_NAMESPACE_DC_10, 'subject') as $category)
                {
-                       $categories[] =& new $this->item->feed->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $categories[] = new $this->item->feed->category_class($this->sanitize($category['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
 
                if (!empty($categories))
@@ -5871,7 +5521,7 @@ class SimplePie_Source
                }
        }
 
-       function get_author($key = 0)
+       public function get_author($key = 0)
        {
                $authors = $this->get_authors();
                if (isset($authors[$key]))
@@ -5884,7 +5534,7 @@ class SimplePie_Source
                }
        }
 
-       function get_authors()
+       public function get_authors()
        {
                $authors = array();
                foreach ((array) $this->get_source_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'author') as $author)
@@ -5906,7 +5556,7 @@ class SimplePie_Source
                        }
                        if ($name !== null || $email !== null || $uri !== null)
                        {
-                               $authors[] =& new $this->item->feed->author_class($name, $uri, $email);
+                               $authors[] = new $this->item->feed->author_class($name, $uri, $email);
                        }
                }
                if ($author = $this->get_source_tags(SIMPLEPIE_NAMESPACE_ATOM_03, 'author'))
@@ -5928,20 +5578,20 @@ class SimplePie_Source
                        }
                        if ($name !== null || $email !== null || $url !== null)
                        {
-                               $authors[] =& new $this->item->feed->author_class($name, $url, $email);
+                               $authors[] = new $this->item->feed->author_class($name, $url, $email);
                        }
                }
                foreach ((array) $this->get_source_tags(SIMPLEPIE_NAMESPACE_DC_11, 'creator') as $author)
                {
-                       $authors[] =& new $this->item->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $authors[] = new $this->item->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
                foreach ((array) $this->get_source_tags(SIMPLEPIE_NAMESPACE_DC_10, 'creator') as $author)
                {
-                       $authors[] =& new $this->item->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $authors[] = new $this->item->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
                foreach ((array) $this->get_source_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'author') as $author)
                {
-                       $authors[] =& new $this->item->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
+                       $authors[] = new $this->item->feed->author_class($this->sanitize($author['data'], SIMPLEPIE_CONSTRUCT_TEXT), null, null);
                }
 
                if (!empty($authors))
@@ -5954,7 +5604,7 @@ class SimplePie_Source
                }
        }
 
-       function get_contributor($key = 0)
+       public function get_contributor($key = 0)
        {
                $contributors = $this->get_contributors();
                if (isset($contributors[$key]))
@@ -5967,7 +5617,7 @@ class SimplePie_Source
                }
        }
 
-       function get_contributors()
+       public function get_contributors()
        {
                $contributors = array();
                foreach ((array) $this->get_source_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'contributor') as $contributor)
@@ -5989,7 +5639,7 @@ class SimplePie_Source
                        }
                        if ($name !== null || $email !== null || $uri !== null)
                        {
-                               $contributors[] =& new $this->item->feed->author_class($name, $uri, $email);
+                               $contributors[] = new $this->item->feed->author_class($name, $uri, $email);
                        }
                }
                foreach ((array) $this->get_source_tags(SIMPLEPIE_NAMESPACE_ATOM_03, 'contributor') as $contributor)
@@ -6011,7 +5661,7 @@ class SimplePie_Source
                        }
                        if ($name !== null || $email !== null || $url !== null)
                        {
-                               $contributors[] =& new $this->item->feed->author_class($name, $url, $email);
+                               $contributors[] = new $this->item->feed->author_class($name, $url, $email);
                        }
                }
 
@@ -6025,7 +5675,7 @@ class SimplePie_Source
                }
        }
 
-       function get_link($key = 0, $rel = 'alternate')
+       public function get_link($key = 0, $rel = 'alternate')
        {
                $links = $this->get_links($rel);
                if (isset($links[$key]))
@@ -6041,12 +5691,12 @@ class SimplePie_Source
        /**
         * Added for parity between the parent-level and the item/entry-level.
         */
-       function get_permalink()
+       public function get_permalink()
        {
                return $this->get_link(0);
        }
 
-       function get_links($rel = 'alternate')
+       public function get_links($rel = 'alternate')
        {
                if (!isset($this->data['links']))
                {
@@ -6120,7 +5770,7 @@ class SimplePie_Source
                }
        }
 
-       function get_description()
+       public function get_description()
        {
                if ($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'subtitle'))
                {
@@ -6164,7 +5814,7 @@ class SimplePie_Source
                }
        }
 
-       function get_copyright()
+       public function get_copyright()
        {
                if ($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_ATOM_10, 'rights'))
                {
@@ -6192,7 +5842,7 @@ class SimplePie_Source
                }
        }
 
-       function get_language()
+       public function get_language()
        {
                if ($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_RSS_20, 'language'))
                {
@@ -6216,13 +5866,13 @@ class SimplePie_Source
                }
        }
 
-       function get_latitude()
+       public function get_latitude()
        {
                if ($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_W3C_BASIC_GEO, 'lat'))
                {
                        return (float) $return[0]['data'];
                }
-               elseif (($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', $return[0]['data'], $match))
+               elseif (($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', trim($return[0]['data']), $match))
                {
                        return (float) $match[1];
                }
@@ -6232,7 +5882,7 @@ class SimplePie_Source
                }
        }
 
-       function get_longitude()
+       public function get_longitude()
        {
                if ($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_W3C_BASIC_GEO, 'long'))
                {
@@ -6242,7 +5892,7 @@ class SimplePie_Source
                {
                        return (float) $return[0]['data'];
                }
-               elseif (($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', $return[0]['data'], $match))
+               elseif (($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_GEORSS, 'point')) && preg_match('/^((?:-)?[0-9]+(?:\.[0-9]+)) ((?:-)?[0-9]+(?:\.[0-9]+))$/', trim($return[0]['data']), $match))
                {
                        return (float) $match[2];
                }
@@ -6252,7 +5902,7 @@ class SimplePie_Source
                }
        }
 
-       function get_image_url()
+       public function get_image_url()
        {
                if ($return = $this->get_source_tags(SIMPLEPIE_NAMESPACE_ITUNES, 'image'))
                {
@@ -6280,20 +5930,20 @@ class SimplePie_Author
        var $email;
 
        // Constructor, used to input the data
-       function SimplePie_Author($name = null, $link = null, $email = null)
+       public function __construct($name = null, $link = null, $email = null)
        {
                $this->name = $name;
                $this->link = $link;
                $this->email = $email;
        }
 
-       function __toString()
+       public function __toString()
        {
                // There is no $this->data here
                return md5(serialize($this));
        }
 
-       function get_name()
+       public function get_name()
        {
                if ($this->name !== null)
                {
@@ -6305,7 +5955,7 @@ class SimplePie_Author
                }
        }
 
-       function get_link()
+       public function get_link()
        {
                if ($this->link !== null)
                {
@@ -6317,7 +5967,7 @@ class SimplePie_Author
                }
        }
 
-       function get_email()
+       public function get_email()
        {
                if ($this->email !== null)
                {
@@ -6337,20 +5987,20 @@ class SimplePie_Category
        var $label;
 
        // Constructor, used to input the data
-       function SimplePie_Category($term = null, $scheme = null, $label = null)
+       public function __construct($term = null, $scheme = null, $label = null)
        {
                $this->term = $term;
                $this->scheme = $scheme;
                $this->label = $label;
        }
 
-       function __toString()
+       public function __toString()
        {
                // There is no $this->data here
                return md5(serialize($this));
        }
 
-       function get_term()
+       public function get_term()
        {
                if ($this->term !== null)
                {
@@ -6362,7 +6012,7 @@ class SimplePie_Category
                }
        }
 
-       function get_scheme()
+       public function get_scheme()
        {
                if ($this->scheme !== null)
                {
@@ -6374,7 +6024,7 @@ class SimplePie_Category
                }
        }
 
-       function get_label()
+       public function get_label()
        {
                if ($this->label !== null)
                {
@@ -6418,7 +6068,7 @@ class SimplePie_Enclosure
        var $width;
 
        // Constructor, used to input the data
-       function SimplePie_Enclosure($link = null, $type = null, $length = null, $javascript = null, $bitrate = null, $captions = null, $categories = null, $channels = null, $copyright = null, $credits = null, $description = null, $duration = null, $expression = null, $framerate = null, $hashes = null, $height = null, $keywords = null, $lang = null, $medium = null, $player = null, $ratings = null, $restrictions = null, $samplingrate = null, $thumbnails = null, $title = null, $width = null)
+       public function __construct($link = null, $type = null, $length = null, $javascript = null, $bitrate = null, $captions = null, $categories = null, $channels = null, $copyright = null, $credits = null, $description = null, $duration = null, $expression = null, $framerate = null, $hashes = null, $height = null, $keywords = null, $lang = null, $medium = null, $player = null, $ratings = null, $restrictions = null, $samplingrate = null, $thumbnails = null, $title = null, $width = null)
        {
                $this->bitrate = $bitrate;
                $this->captions = $captions;
@@ -6446,22 +6096,23 @@ class SimplePie_Enclosure
                $this->title = $title;
                $this->type = $type;
                $this->width = $width;
+
                if (class_exists('idna_convert'))
                {
-                       $idn =& new idna_convert;
+                       $idn = new idna_convert();
                        $parsed = SimplePie_Misc::parse_url($link);
                        $this->link = SimplePie_Misc::compress_parse_url($parsed['scheme'], $idn->encode($parsed['authority']), $parsed['path'], $parsed['query'], $parsed['fragment']);
                }
                $this->handler = $this->get_handler(); // Needs to load last
        }
 
-       function __toString()
+       public function __toString()
        {
                // There is no $this->data here
                return md5(serialize($this));
        }
 
-       function get_bitrate()
+       public function get_bitrate()
        {
                if ($this->bitrate !== null)
                {
@@ -6473,7 +6124,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_caption($key = 0)
+       public function get_caption($key = 0)
        {
                $captions = $this->get_captions();
                if (isset($captions[$key]))
@@ -6486,7 +6137,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_captions()
+       public function get_captions()
        {
                if ($this->captions !== null)
                {
@@ -6498,7 +6149,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_category($key = 0)
+       public function get_category($key = 0)
        {
                $categories = $this->get_categories();
                if (isset($categories[$key]))
@@ -6511,7 +6162,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_categories()
+       public function get_categories()
        {
                if ($this->categories !== null)
                {
@@ -6523,7 +6174,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_channels()
+       public function get_channels()
        {
                if ($this->channels !== null)
                {
@@ -6535,7 +6186,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_copyright()
+       public function get_copyright()
        {
                if ($this->copyright !== null)
                {
@@ -6547,7 +6198,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_credit($key = 0)
+       public function get_credit($key = 0)
        {
                $credits = $this->get_credits();
                if (isset($credits[$key]))
@@ -6560,7 +6211,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_credits()
+       public function get_credits()
        {
                if ($this->credits !== null)
                {
@@ -6572,7 +6223,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_description()
+       public function get_description()
        {
                if ($this->description !== null)
                {
@@ -6584,7 +6235,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_duration($convert = false)
+       public function get_duration($convert = false)
        {
                if ($this->duration !== null)
                {
@@ -6604,7 +6255,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_expression()
+       public function get_expression()
        {
                if ($this->expression !== null)
                {
@@ -6616,7 +6267,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_extension()
+       public function get_extension()
        {
                if ($this->link !== null)
                {
@@ -6629,7 +6280,7 @@ class SimplePie_Enclosure
                return null;
        }
 
-       function get_framerate()
+       public function get_framerate()
        {
                if ($this->framerate !== null)
                {
@@ -6641,12 +6292,12 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_handler()
+       public function get_handler()
        {
                return $this->get_real_type(true);
        }
 
-       function get_hash($key = 0)
+       public function get_hash($key = 0)
        {
                $hashes = $this->get_hashes();
                if (isset($hashes[$key]))
@@ -6659,7 +6310,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_hashes()
+       public function get_hashes()
        {
                if ($this->hashes !== null)
                {
@@ -6671,7 +6322,7 @@ class SimplePie_Enclosure
                }
        }
 
-       function get_height()
+       public function get_height()
        {
                if ($this->height !== null)
                {