From 001ea42d96ffbc367f6e65a764e1788c9e0671c9 Mon Sep 17 00:00:00 2001 From: Grischa Brockhaus Date: Thu, 14 Jun 2012 12:05:52 +0200 Subject: [PATCH] Fixed simplepie to make it work with E_STRICT. --- bundled-libs/simplepie/simplepie.inc | 366 +++++++++++++-------------- 1 file changed, 183 insertions(+), 183 deletions(-) diff --git a/bundled-libs/simplepie/simplepie.inc b/bundled-libs/simplepie/simplepie.inc index c2e9509e..084f54e9 100644 --- a/bundled-libs/simplepie/simplepie.inc +++ b/bundled-libs/simplepie/simplepie.inc @@ -735,7 +735,7 @@ class SimplePie function SimplePie($feed_url = null, $cache_location = null, $cache_duration = null) { // Other objects, instances created here so we can set options on them - $this->sanitize =& new SimplePie_Sanitize; + $this->sanitize = new SimplePie_Sanitize; // Set options if they're passed to the constructor if ($cache_location !== null) @@ -1105,7 +1105,7 @@ class SimplePie { if (SimplePie_Misc::is_subclass_of($class, 'SimplePie_Sanitize')) { - $this->sanitize =& new $class; + $this->sanitize = new $class; return true; } return false; @@ -1599,7 +1599,7 @@ 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) @@ -1640,7 +1640,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 @@ -1660,7 +1660,7 @@ 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 @@ -1690,7 +1690,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 @@ -1760,7 +1760,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')) @@ -1971,11 +1971,11 @@ class SimplePie } else { - $file =& new $this->file_class($favicon, $this->timeout / 10, 5, array('X-FORWARDED-FOR' => $_SERVER['REMOTE_ADDR']), $this->useragent, $this->force_fsockopen); + $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); + $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))) @@ -2374,7 +2374,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) { @@ -2389,15 +2389,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)) @@ -2445,7 +2445,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')) @@ -2467,20 +2467,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)) @@ -2528,7 +2528,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) @@ -2550,7 +2550,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); } } @@ -2964,7 +2964,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')) @@ -2972,7 +2972,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')) @@ -2980,7 +2980,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')) @@ -2988,7 +2988,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')) @@ -2996,7 +2996,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]); } } } @@ -3352,7 +3352,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) { @@ -3367,15 +3367,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)) @@ -3436,7 +3436,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) @@ -3458,7 +3458,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); } } @@ -3494,7 +3494,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')) @@ -3516,24 +3516,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)) @@ -3843,7 +3843,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')) @@ -3875,7 +3875,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)) @@ -3905,7 +3905,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) { @@ -3928,7 +3928,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) { @@ -3939,7 +3939,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'])) { @@ -3949,7 +3949,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); } } } @@ -3971,7 +3971,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')) { @@ -3985,7 +3985,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 @@ -4012,7 +4012,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')) @@ -4038,7 +4038,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)) @@ -4227,7 +4227,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')) @@ -4240,7 +4240,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')) @@ -4261,7 +4261,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')) @@ -4274,7 +4274,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)) @@ -4302,7 +4302,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')) @@ -4316,7 +4316,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')) @@ -4338,7 +4338,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')) @@ -4352,7 +4352,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)) @@ -4558,7 +4558,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)) { @@ -4594,7 +4594,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)) { @@ -4630,7 +4630,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 (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['category'])) @@ -4656,7 +4656,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)) @@ -4685,7 +4685,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); } elseif (isset($group['child'][SIMPLEPIE_NAMESPACE_MEDIARSS]['copyright'])) { @@ -4699,7 +4699,7 @@ class SimplePie_Item { $copyright_label = $this->sanitize($group['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 { @@ -4730,7 +4730,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)) { @@ -4760,7 +4760,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)) { @@ -4913,7 +4913,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)) { @@ -4938,7 +4938,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)) { @@ -4970,7 +4970,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)) { @@ -4996,7 +4996,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)) { @@ -5050,7 +5050,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); } } } @@ -5182,7 +5182,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)) { @@ -5218,7 +5218,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)) @@ -5251,7 +5251,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 { @@ -5282,7 +5282,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)) { @@ -5386,7 +5386,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)) { @@ -5418,7 +5418,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)) { @@ -5457,7 +5457,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); } } } @@ -5493,7 +5493,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); } } @@ -5528,7 +5528,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); } } @@ -5563,14 +5563,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'])); @@ -5847,7 +5847,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) { @@ -5862,15 +5862,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)) @@ -5918,7 +5918,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')) @@ -5940,20 +5940,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)) @@ -6001,7 +6001,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) @@ -6023,7 +6023,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); } } @@ -6460,7 +6460,7 @@ class SimplePie_Enclosure $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']); } @@ -7658,7 +7658,7 @@ class SimplePie_File { if (class_exists('idna_convert')) { - $idn =& new idna_convert; + $idn = new idna_convert; $parsed = SimplePie_Misc::parse_url($url); $url = SimplePie_Misc::compress_parse_url($parsed['scheme'], $idn->encode($parsed['authority']), $parsed['path'], $parsed['query'], $parsed['fragment']); } @@ -7719,7 +7719,7 @@ class SimplePie_File curl_close($fp); $this->headers = explode("\r\n\r\n", $this->headers, $info['redirect_count'] + 1); $this->headers = array_pop($this->headers); - $parser =& new SimplePie_HTTP_Parser($this->headers); + $parser = new SimplePie_HTTP_Parser($this->headers); if ($parser->parse()) { $this->headers = $parser->headers; @@ -7801,7 +7801,7 @@ class SimplePie_File } if (!$info['timed_out']) { - $parser =& new SimplePie_HTTP_Parser($this->headers); + $parser = new SimplePie_HTTP_Parser($this->headers); if ($parser->parse()) { $this->headers = $parser->headers; @@ -7820,7 +7820,7 @@ class SimplePie_File { case 'gzip': case 'x-gzip': - $decoder =& new SimplePie_gzdecode($this->body); + $decoder = new SimplePie_gzdecode($this->body); if (!$decoder->parse()) { $this->error = 'Unable to decode HTTP "gzip" stream'; @@ -8632,7 +8632,7 @@ class SimplePie_Cache */ function create($location, $filename, $extension) { - $location_iri =& new SimplePie_IRI($location); + $location_iri = new SimplePie_IRI($location); switch ($location_iri->get_scheme()) { case 'mysql': @@ -9111,7 +9111,7 @@ class SimplePie_Misc return $time; } - function absolutize_url($relative, $base) + static function absolutize_url($relative, $base) { $iri = SimplePie_IRI::absolutize(new SimplePie_IRI($base), $relative); return $iri->get_iri(); @@ -9171,7 +9171,7 @@ class SimplePie_Misc return $output . $input; } - function get_element($realname, $string) + static function get_element($realname, $string) { $return = array(); $name = preg_quote($realname, '/'); @@ -9208,7 +9208,7 @@ class SimplePie_Misc return $return; } - function element_implode($element) + static function element_implode($element) { $full = "<$element[tag]"; foreach ($element['attribs'] as $key => $value) @@ -9312,7 +9312,7 @@ class SimplePie_Misc die('Cached file for ' . $identifier_url . ' cannot be found.'); } - function fix_protocol($url, $http = 1) + static function fix_protocol($url, $http = 1) { $url = SimplePie_Misc::normalize_url($url); $parsed = SimplePie_Misc::parse_url($url); @@ -9344,9 +9344,9 @@ class SimplePie_Misc } } - function parse_url($url) + static function parse_url($url) { - $iri =& new SimplePie_IRI($url); + $iri = new SimplePie_IRI($url); return array( 'scheme' => (string) $iri->get_scheme(), 'authority' => (string) $iri->get_authority(), @@ -9358,7 +9358,7 @@ class SimplePie_Misc function compress_parse_url($scheme = '', $authority = '', $path = '', $query = '', $fragment = '') { - $iri =& new SimplePie_IRI(''); + $iri = new SimplePie_IRI(''); $iri->set_scheme($scheme); $iri->set_authority($authority); $iri->set_path($path); @@ -9367,9 +9367,9 @@ class SimplePie_Misc return $iri->get_iri(); } - function normalize_url($url) + static function normalize_url($url) { - $iri =& new SimplePie_IRI($url); + $iri = new SimplePie_IRI($url); return $iri->get_iri(); } @@ -9436,7 +9436,7 @@ class SimplePie_Misc return strtr($string, $convert_table); } - function change_encoding($data, $input, $output) + static function change_encoding($data, $input, $output) { $input = SimplePie_Misc::encoding($input); $output = SimplePie_Misc::encoding($output); @@ -9488,7 +9488,7 @@ class SimplePie_Misc * @param string $charset Character set to standardise * @return string Standardised name */ - function encoding($charset) + static function encoding($charset) { // Normalization from UTS #22 switch (strtolower(preg_replace('/(?:[^a-zA-Z0-9]+|([^0-9])0+)/', '\1', $charset))) @@ -10801,7 +10801,7 @@ class SimplePie_Misc } } - function get_curl_version() + static function get_curl_version() { if (is_array($curl = curl_version())) { @@ -10895,9 +10895,9 @@ class SimplePie_Misc * @param string $data Input data * @return string Output data */ - function entities_decode($data) + static function entities_decode($data) { - $decoder =& new SimplePie_Decode_HTML_Entities($data); + $decoder = new SimplePie_Decode_HTML_Entities($data); return $decoder->parse(); } @@ -11075,7 +11075,7 @@ class SimplePie_Misc } } - function is_isegment_nz_nc($string) + static function is_isegment_nz_nc($string) { return (bool) preg_match('/^([A-Za-z0-9\-._~\x{A0}-\x{D7FF}\x{F900}-\x{FDCF}\x{FDF0}-\x{FFEF}\x{10000}-\x{1FFFD}\x{20000}-\x{2FFFD}\x{30000}-\x{3FFFD}\x{40000}-\x{4FFFD}\x{50000}-\x{5FFFD}\x{60000}-\x{6FFFD}\x{70000}-\x{7FFFD}\x{80000}-\x{8FFFD}\x{90000}-\x{9FFFD}\x{A0000}-\x{AFFFD}\x{B0000}-\x{BFFFD}\x{C0000}-\x{CFFFD}\x{D0000}-\x{DFFFD}\x{E1000}-\x{EFFFD}!$&\'()*+,;=@]|(%[0-9ABCDEF]{2}))+$/u', $string); } @@ -11099,7 +11099,7 @@ class SimplePie_Misc return $tokens; } - function array_unique($array) + static function array_unique($array) { if (version_compare(PHP_VERSION, '5.2', '>=')) { @@ -11261,7 +11261,7 @@ class SimplePie_Misc * @param string $data XML data * @return array Possible encodings */ - function xml_encoding($data) + static function xml_encoding($data) { // UTF-32 Big Endian BOM if (substr($data, 0, 4) === "\x00\x00\xFE\xFF") @@ -11293,7 +11293,7 @@ class SimplePie_Misc { if ($pos = strpos($data, "\x00\x00\x00\x3F\x00\x00\x00\x3E")) { - $parser =& new SimplePie_XML_Declaration_Parser(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 20), 'UTF-32BE', 'UTF-8')); + $parser = new SimplePie_XML_Declaration_Parser(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 20), 'UTF-32BE', 'UTF-8')); if ($parser->parse()) { $encoding[] = $parser->encoding; @@ -11306,7 +11306,7 @@ class SimplePie_Misc { if ($pos = strpos($data, "\x3F\x00\x00\x00\x3E\x00\x00\x00")) { - $parser =& new SimplePie_XML_Declaration_Parser(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 20), 'UTF-32LE', 'UTF-8')); + $parser = new SimplePie_XML_Declaration_Parser(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 20), 'UTF-32LE', 'UTF-8')); if ($parser->parse()) { $encoding[] = $parser->encoding; @@ -11319,7 +11319,7 @@ class SimplePie_Misc { if ($pos = strpos($data, "\x00\x3F\x00\x3E")) { - $parser =& new SimplePie_XML_Declaration_Parser(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 10), 'UTF-16BE', 'UTF-8')); + $parser = new SimplePie_XML_Declaration_Parser(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 10), 'UTF-16BE', 'UTF-8')); if ($parser->parse()) { $encoding[] = $parser->encoding; @@ -11332,7 +11332,7 @@ class SimplePie_Misc { if ($pos = strpos($data, "\x3F\x00\x3E\x00")) { - $parser =& new SimplePie_XML_Declaration_Parser(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 10), 'UTF-16LE', 'UTF-8')); + $parser = new SimplePie_XML_Declaration_Parser(SimplePie_Misc::change_encoding(substr($data, 20, $pos - 10), 'UTF-16LE', 'UTF-8')); if ($parser->parse()) { $encoding[] = $parser->encoding; @@ -11345,7 +11345,7 @@ class SimplePie_Misc { if ($pos = strpos($data, "\x3F\x3E")) { - $parser =& new SimplePie_XML_Declaration_Parser(substr($data, 5, $pos - 5)); + $parser = new SimplePie_XML_Declaration_Parser(substr($data, 5, $pos - 5)); if ($parser->parse()) { $encoding[] = $parser->encoding; @@ -11767,12 +11767,12 @@ class SimplePie_IRI * @param string $relative Relative IRI * @return SimplePie_IRI */ - function absolutize($base, $relative) + static function absolutize($base, $relative) { $relative = (string) $relative; if ($relative !== '') { - $relative =& new SimplePie_IRI($relative); + $relative = new SimplePie_IRI($relative); if ($relative->get_scheme() !== null) { $target = $relative; @@ -11786,7 +11786,7 @@ class SimplePie_IRI } else { - $target =& new SimplePie_IRI(''); + $target = new SimplePie_IRI(''); $target->set_scheme($base->get_scheme()); $target->set_userinfo($base->get_userinfo()); $target->set_host($base->get_host()); @@ -12879,20 +12879,20 @@ class SimplePie_Parse_Date 'sonnabend' => 6, 'sonntag' => 7, // Italian - 'lunedì' => 1, - 'martedì' => 2, - 'mercoledì' => 3, - 'giovedì' => 4, - 'venerdì' => 5, + 'lunedì' => 1, + 'martedì' => 2, + 'mercoledì' => 3, + 'giovedì' => 4, + 'venerdì' => 5, 'sabato' => 6, 'domenica' => 7, // Spanish 'lunes' => 1, 'martes' => 2, - 'miércoles' => 3, + 'miércoles' => 3, 'jueves' => 4, 'viernes' => 5, - 'sábado' => 6, + 'sábado' => 6, 'domingo' => 7, // Finnish 'maanantai' => 1, @@ -12903,21 +12903,21 @@ class SimplePie_Parse_Date 'lauantai' => 6, 'sunnuntai' => 7, // Hungarian - 'hétfő' => 1, + 'hétfÅ‘' => 1, 'kedd' => 2, 'szerda' => 3, - 'csütörtok' => 4, - 'péntek' => 5, + 'csütörtok' => 4, + 'péntek' => 5, 'szombat' => 6, - 'vasárnap' => 7, + 'vasárnap' => 7, // Greek - 'Δευ' => 1, - 'Τρι' => 2, - 'Τετ' => 3, - 'Πεμ' => 4, - 'Παρ' => 5, - 'Σαβ' => 6, - 'Κυρ' => 7, + 'Δευ' => 1, + 'ΤÏ�ι' => 2, + 'Τετ' => 3, + 'Πεμ' => 4, + 'ΠαÏ�' => 5, + 'Σαβ' => 6, + 'ΚυÏ�' => 7, ); /** @@ -12967,21 +12967,21 @@ class SimplePie_Parse_Date 'december' => 12, // French 'janvier' => 1, - 'février' => 2, + 'février' => 2, 'mars' => 3, 'avril' => 4, 'mai' => 5, 'juin' => 6, 'juillet' => 7, - 'août' => 8, + 'août' => 8, 'septembre' => 9, 'octobre' => 10, 'novembre' => 11, - 'décembre' => 12, + 'décembre' => 12, // German 'januar' => 1, 'februar' => 2, - 'märz' => 3, + 'märz' => 3, 'april' => 4, 'mai' => 5, 'juni' => 6, @@ -13024,45 +13024,45 @@ class SimplePie_Parse_Date 'maaliskuu' => 3, 'huhtikuu' => 4, 'toukokuu' => 5, - 'kesäkuu' => 6, - 'heinäkuu' => 7, + 'kesäkuu' => 6, + 'heinäkuu' => 7, 'elokuu' => 8, 'suuskuu' => 9, 'lokakuu' => 10, 'marras' => 11, 'joulukuu' => 12, // Hungarian - 'január' => 1, - 'február' => 2, - 'március' => 3, - 'április' => 4, - 'május' => 5, - 'június' => 6, - 'július' => 7, + 'január' => 1, + 'február' => 2, + 'március' => 3, + 'április' => 4, + 'május' => 5, + 'június' => 6, + 'július' => 7, 'augusztus' => 8, 'szeptember' => 9, - 'október' => 10, + 'október' => 10, 'november' => 11, 'december' => 12, // Greek - 'Ιαν' => 1, - 'Φεβ' => 2, - 'Μάώ' => 3, - 'Μαώ' => 3, - 'Απρ' => 4, - 'Μάι' => 5, - 'Μαϊ' => 5, - 'Μαι' => 5, - 'Ιούν' => 6, - 'Ιον' => 6, - 'Ιούλ' => 7, - 'Ιολ' => 7, - 'Αύγ' => 8, - 'Αυγ' => 8, - 'Σεπ' => 9, - 'Οκτ' => 10, - 'Νοέ' => 11, - 'Δεκ' => 12, + 'Ιαν' => 1, + 'Φεβ' => 2, + 'Μάώ' => 3, + 'Μαώ' => 3, + 'ΑπÏ�' => 4, + 'Μάι' => 5, + 'Μαϊ' => 5, + 'Μαι' => 5, + 'ΙοÏ�ν' => 6, + 'Ιον' => 6, + 'ΙοÏ�λ' => 7, + 'Ιολ' => 7, + 'ΑÏ�γ' => 8, + 'Αυγ' => 8, + 'Σεπ' => 9, + 'Οκτ' => 10, + 'Î�οέ' => 11, + 'Δεκ' => 12, ); /** @@ -13341,12 +13341,12 @@ class SimplePie_Parse_Date * * @access public */ - function get() + static function get() { static $object; if (!$object) { - $object =& new SimplePie_Parse_Date; + $object = new SimplePie_Parse_Date; } return $object; } @@ -13430,7 +13430,7 @@ class SimplePie_Parse_Date 6: Second 7: Decimal fraction of a second 8: Zulu - 9: Timezone ± + 9: Timezone ± 10: Timezone hours 11: Timezone minutes */ @@ -13568,7 +13568,7 @@ class SimplePie_Parse_Date 5: Hour 6: Minute 7: Second - 8: Timezone ± + 8: Timezone ± 9: Timezone hours 10: Timezone minutes 11: Alphabetic timezone @@ -14381,7 +14381,7 @@ class SimplePie_Locator if ($this->file->method & SIMPLEPIE_FILE_SOURCE_REMOTE) { - $sniffer =& new $this->content_type_sniffer_class($this->file); + $sniffer = new $this->content_type_sniffer_class($this->file); if ($sniffer->get_type() !== 'text/html') { return null; @@ -14427,7 +14427,7 @@ class SimplePie_Locator { if ($file->method & SIMPLEPIE_FILE_SOURCE_REMOTE) { - $sniffer =& new $this->content_type_sniffer_class($file); + $sniffer = new $this->content_type_sniffer_class($file); $sniffed = $sniffer->get_type(); if (in_array($sniffed, array('application/rss+xml', 'application/rdf+xml', 'text/rdf', 'application/atom+xml', 'text/xml', 'application/xml'))) { @@ -14491,7 +14491,7 @@ class SimplePie_Locator if (!in_array($href, $done) && in_array('feed', $rel) || (in_array('alternate', $rel) && !empty($link['attribs']['type']['data']) && in_array(strtolower(SimplePie_Misc::parse_mime($link['attribs']['type']['data'])), array('application/rss+xml', 'application/atom+xml'))) && !isset($feeds[$href])) { $this->checked_feeds++; - $feed =& new $this->file_class($href, $this->timeout, 5, null, $this->useragent); + $feed = new $this->file_class($href, $this->timeout, 5, null, $this->useragent); if ($feed->success && ($feed->method & SIMPLEPIE_FILE_SOURCE_REMOTE === 0 || ($feed->status_code === 200 || $feed->status_code > 206 && $feed->status_code < 300)) && $this->is_feed($feed)) { $feeds[$href] = $feed; @@ -14563,7 +14563,7 @@ class SimplePie_Locator if (in_array(strtolower(strrchr($value, '.')), array('.rss', '.rdf', '.atom', '.xml'))) { $this->checked_feeds++; - $feed =& new $this->file_class($value, $this->timeout, 5, null, $this->useragent); + $feed = new $this->file_class($value, $this->timeout, 5, null, $this->useragent); if ($feed->success && ($feed->method & SIMPLEPIE_FILE_SOURCE_REMOTE === 0 || ($feed->status_code === 200 || $feed->status_code > 206 && $feed->status_code < 300)) && $this->is_feed($feed)) { return $feed; @@ -14588,7 +14588,7 @@ class SimplePie_Locator if (preg_match('/(rss|rdf|atom|xml)/i', $value)) { $this->checked_feeds++; - $feed =& new $this->file_class($value, $this->timeout, 5, null, $this->useragent); + $feed = new $this->file_class($value, $this->timeout, 5, null, $this->useragent); if ($feed->success && ($feed->method & SIMPLEPIE_FILE_SOURCE_REMOTE === 0 || ($feed->status_code === 200 || $feed->status_code > 206 && $feed->status_code < 300)) && $this->is_feed($feed)) { return $feed; @@ -14662,7 +14662,7 @@ class SimplePie_Parser if (substr($data, 0, 5) === '')) !== false) { - $declaration =& new SimplePie_XML_Declaration_Parser(substr($data, 5, $pos - 5)); + $declaration = new SimplePie_XML_Declaration_Parser(substr($data, 5, $pos - 5)); if ($declaration->parse()) { $data = substr($data, $pos + 2); @@ -14712,7 +14712,7 @@ class SimplePie_Parser else { libxml_clear_errors(); - $xml =& new XMLReader(); + $xml = new XMLReader(); $xml->xml($data); while (@$xml->read()) { @@ -15198,7 +15198,7 @@ class SimplePie_Sanitize } else { - $file =& new $this->file_class($img['attribs']['src']['data'], $this->timeout, 5, array('X-FORWARDED-FOR' => $_SERVER['REMOTE_ADDR']), $this->useragent, $this->force_fsockopen); + $file = new $this->file_class($img['attribs']['src']['data'], $this->timeout, 5, array('X-FORWARDED-FOR' => $_SERVER['REMOTE_ADDR']), $this->useragent, $this->force_fsockopen); $headers = $file->headers; if ($file->success && ($file->method & SIMPLEPIE_FILE_SOURCE_REMOTE === 0 || ($file->status_code === 200 || $file->status_code > 206 && $file->status_code < 300)))