Ticket #22321: 22321.patch
| File 22321.patch, 25.8 KB (added by , 13 years ago) |
|---|
-
wp-includes/SimplePie/HTTP/Parser.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Misc.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon … … 80 80 public static function absolutize_url($relative, $base) 81 81 { 82 82 $iri = SimplePie_IRI::absolutize(new SimplePie_IRI($base), $relative); 83 if ( $iri ) 84 return $iri->get_uri(); 85 return $relative; 83 if ($iri === false) 84 { 85 return false; 86 } 87 return $iri->get_uri(); 86 88 } 87 89 88 90 /** -
wp-includes/SimplePie/Parser.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon … … 278 278 279 279 if (isset($attribs[SIMPLEPIE_NAMESPACE_XML]['base'])) 280 280 { 281 $this->xml_base[] = $this->registry->call('Misc', 'absolutize_url', array($attribs[SIMPLEPIE_NAMESPACE_XML]['base'], end($this->xml_base))); 282 $this->xml_base_explicit[] = true; 281 $base = $this->registry->call('Misc', 'absolutize_url', array($attribs[SIMPLEPIE_NAMESPACE_XML]['base'], end($this->xml_base))); 282 if ($base !== false) 283 { 284 $this->xml_base[] = $base; 285 $this->xml_base_explicit[] = true; 286 } 283 287 } 284 288 else 285 289 { -
wp-includes/SimplePie/Caption.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Item.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Enclosure.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Source.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Net/IPv6.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Registry.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon … … 203 203 { 204 204 $class = $this->get_class($type); 205 205 206 if (in_array($class, $this->legacy)) 207 { 208 switch ($type) 209 { 210 case 'Cache': 211 // For backwards compatibility with old non-static 212 // Cache::create() methods 213 if ($method === 'get_handler') 214 { 215 $result = @call_user_func_array(array($class, 'create'), $parameters); 216 return $result; 217 } 218 break; 219 } 220 } 221 206 222 $result = call_user_func_array(array($class, $method), $parameters); 207 223 return $result; 208 224 } -
wp-includes/SimplePie/Copyright.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/XML/Declaration/Parser.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/IRI.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon … … 390 390 } 391 391 else 392 392 { 393 trigger_error('This should never happen', E_USER_ERROR);394 die;393 // This can occur when a paragraph is accidentally parsed as a URI 394 return false; 395 395 } 396 396 } 397 397 … … 824 824 else 825 825 { 826 826 $parsed = $this->parse_iri((string) $iri); 827 if (!$parsed) 828 { 829 return false; 830 } 827 831 828 832 $return = $this->set_scheme($parsed['scheme']) 829 833 && $this->set_authority($parsed['authority']) -
wp-includes/SimplePie/Rating.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Sanitize.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon … … 302 302 if ($img->hasAttribute('src')) 303 303 { 304 304 $image_url = call_user_func($this->cache_name_function, $img->getAttribute('src')); 305 $cache = $this->registry->call('Cache', ' create', array($this->cache_location, $image_url, 'spi'));305 $cache = $this->registry->call('Cache', 'get_handler', array($this->cache_location, $image_url, 'spi')); 306 306 307 307 if ($cache->load()) 308 308 { … … 356 356 357 357 if ($type & SIMPLEPIE_CONSTRUCT_IRI) 358 358 { 359 $data = $this->registry->call('Misc', 'absolutize_url', array($data, $base)); 359 $absolute = $this->registry->call('Misc', 'absolutize_url', array($data, $base)); 360 if ($absolute !== false) 361 { 362 $data = $absolute; 363 } 360 364 } 361 365 362 366 if ($type & (SIMPLEPIE_CONSTRUCT_TEXT | SIMPLEPIE_CONSTRUCT_IRI)) … … 412 416 if ($element->hasAttribute($attribute)) 413 417 { 414 418 $value = $this->registry->call('Misc', 'absolutize_url', array($element->getAttribute($attribute), $this->base)); 415 $element->setAttribute($attribute, $value); 419 if ($value !== false) 420 { 421 $element->setAttribute($attribute, $value); 422 } 416 423 } 417 424 } 418 425 } -
wp-includes/SimplePie/Core.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Decode/HTML/Entities.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Author.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Locator.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon … … 72 72 $this->timeout = $timeout; 73 73 $this->max_checked_feeds = $max_checked_feeds; 74 74 75 $this->dom = new DOMDocument(); 75 if (class_exists('DOMDocument')) 76 { 77 $this->dom = new DOMDocument(); 76 78 77 set_error_handler(array('SimplePie_Misc', 'silence_errors')); 78 $this->dom->loadHTML($this->file->body); 79 restore_error_handler(); 79 set_error_handler(array('SimplePie_Misc', 'silence_errors')); 80 $this->dom->loadHTML($this->file->body); 81 restore_error_handler(); 82 } 83 else 84 { 85 $this->dom = null; 86 } 80 87 } 81 88 82 89 public function set_registry(SimplePie_Registry $registry) … … 162 169 163 170 public function get_base() 164 171 { 172 if ($this->dom === null) 173 { 174 throw new SimplePie_Exception('DOMDocument not found, unable to use locator'); 175 } 165 176 $this->http_base = $this->file->url; 166 177 $this->base = $this->http_base; 167 178 $elements = $this->dom->getElementsByTagName('base'); … … 169 180 { 170 181 if ($element->hasAttribute('href')) 171 182 { 172 $this->base = $this->registry->call('Misc', 'absolutize_url', array(trim($element->getAttribute('href')), $this->http_base)); 183 $base = $this->registry->call('Misc', 'absolutize_url', array(trim($element->getAttribute('href')), $this->http_base)); 184 if ($base === false) 185 { 186 continue; 187 } 188 $this->base = $base; 173 189 $this->base_location = method_exists($element, 'getLineNo') ? $element->getLineNo() : 0; 174 190 break; 175 191 } … … 196 212 197 213 protected function search_elements_by_tag($name, &$done, $feeds) 198 214 { 215 if ($this->dom === null) 216 { 217 throw new SimplePie_Exception('DOMDocument not found, unable to use locator'); 218 } 219 199 220 $links = $this->dom->getElementsByTagName($name); 200 221 foreach ($links as $link) 201 222 { … … 216 237 { 217 238 $href = $this->registry->call('Misc', 'absolutize_url', array(trim($link->getAttribute('href')), $this->http_base)); 218 239 } 240 if ($href === false) 241 { 242 continue; 243 } 219 244 220 245 if (!in_array($href, $done) && in_array('feed', $rel) || (in_array('alternate', $rel) && !in_array('stylesheet', $rel) && $link->hasAttribute('type') && in_array(strtolower($this->registry->call('Misc', 'parse_mime', array($link->getAttribute('type')))), array('application/rss+xml', 'application/atom+xml'))) && !isset($feeds[$href])) 221 246 { … … 238 263 239 264 public function get_links() 240 265 { 266 if ($this->dom === null) 267 { 268 throw new SimplePie_Exception('DOMDocument not found, unable to use locator'); 269 } 270 241 271 $links = $this->dom->getElementsByTagName('a'); 242 272 foreach ($links as $link) 243 273 { … … 255 285 { 256 286 $href = $this->registry->call('Misc', 'absolutize_url', array(trim($link->getAttribute('href')), $this->http_base)); 257 287 } 288 if ($href === false) 289 { 290 continue; 291 } 258 292 259 293 $current = $this->registry->call('Misc', 'parse_url', array($this->file->url)); 260 294 -
wp-includes/SimplePie/Cache.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon … … 79 79 * @param string $extension 'spi' or 'spc' 80 80 * @return SimplePie_Cache_Base Type of object depends on scheme of `$location` 81 81 */ 82 public static function create($location, $filename, $extension)82 public static function get_handler($location, $filename, $extension) 83 83 { 84 84 $type = explode(':', $location, 2); 85 85 $type = $type[0]; … … 93 93 } 94 94 95 95 /** 96 * Create a new SimplePie_Cache object 97 * 98 * @deprecated Use {@see get_handler} instead 99 */ 100 public function create($location, $filename, $extension) 101 { 102 trigger_error('Cache::create() has been replaced with Cache::get_handler(). Switch to the registry system to use this.', E_USER_DEPRECATED); 103 return self::get_handler($location, $filename, $extension); 104 } 105 106 /** 96 107 * Register a handler 97 108 * 98 109 * @param string $type DSN type to register for -
wp-includes/SimplePie/Restriction.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Credit.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Cache/Base.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Cache/File.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Cache/Memcache.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Cache/MySQL.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Cache/DB.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Category.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/File.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Parse/Date.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/Content/Type/Sniffer.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/SimplePie/gzdecode.php
33 33 * POSSIBILITY OF SUCH DAMAGE. 34 34 * 35 35 * @package SimplePie 36 * @version 1.3 36 * @version 1.3.1 37 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 38 38 * @author Ryan Parman 39 39 * @author Geoffrey Sneddon -
wp-includes/class-simplepie.php
93 93 * POSSIBILITY OF SUCH DAMAGE. 94 94 * 95 95 * @package SimplePie 96 * @version 1.3 96 * @version 1.3.1 97 97 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 98 98 * @author Ryan Parman 99 99 * @author Geoffrey Sneddon … … 110 110 /** 111 111 * SimplePie Version 112 112 */ 113 define('SIMPLEPIE_VERSION', '1.3 ');113 define('SIMPLEPIE_VERSION', '1.3.1'); 114 114 115 115 /** 116 116 * SimplePie Build … … 696 696 697 697 if (func_num_args() > 0) 698 698 { 699 trigger_error('Passing parameters to the constructor is no longer supported. Please use set_feed_url(), set_cache_location(), and set_cache_location() directly.'); 699 $level = defined('E_USER_DEPRECATED') ? E_USER_DEPRECATED : E_USER_WARNING; 700 trigger_error('Passing parameters to the constructor is no longer supported. Please use set_feed_url(), set_cache_location(), and set_cache_location() directly.', $level); 701 702 $args = func_get_args(); 703 switch (count($args)) { 704 case 3: 705 $this->set_cache_duration($args[2]); 706 case 2: 707 $this->set_cache_location($args[1]); 708 case 1: 709 $this->set_feed_url($args[0]); 710 $this->init(); 711 } 700 712 } 701 713 } 702 714 … … 1323 1335 // Decide whether to enable caching 1324 1336 if ($this->cache && $parsed_feed_url['scheme'] !== '') 1325 1337 { 1326 $cache = $this->registry->call('Cache', ' create', array($this->cache_location, call_user_func($this->cache_name_function, $this->feed_url), 'spc'));1338 $cache = $this->registry->call('Cache', 'get_handler', array($this->cache_location, call_user_func($this->cache_name_function, $this->feed_url), 'spc')); 1327 1339 } 1328 1340 1329 1341 // Fetch the data via SimplePie_File into $this->raw_data … … 1560 1572 { 1561 1573 // We need to unset this so that if SimplePie::set_file() has been called that object is untouched 1562 1574 unset($file); 1563 if (!($file = $locate->find($this->autodiscovery, $this->all_discovered_feeds)))1575 try 1564 1576 { 1565 $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."; 1566 $this->registry->call('Misc', 'error', array($this->error, E_USER_NOTICE, __FILE__, __LINE__)); 1577 if (!($file = $locate->find($this->autodiscovery, $this->all_discovered_feeds))) 1578 { 1579 $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."; 1580 $this->registry->call('Misc', 'error', array($this->error, E_USER_NOTICE, __FILE__, __LINE__)); 1581 return false; 1582 } 1583 } 1584 catch (SimplePie_Exception $e) 1585 { 1586 // This is usually because DOMDocument doesn't exist 1587 $this->error = $e->getMessage(); 1588 $this->registry->call('Misc', 'error', array($this->error, E_USER_NOTICE, $e->getFile(), $e->getLine())); 1567 1589 return false; 1568 1590 } 1569 1591 if ($cache) … … 1573 1595 { 1574 1596 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); 1575 1597 } 1576 $cache = $this->registry->call('Cache', ' create', array($this->cache_location, call_user_func($this->cache_name_function, $file->url), 'spc'));1598 $cache = $this->registry->call('Cache', 'get_handler', array($this->cache_location, call_user_func($this->cache_name_function, $file->url), 'spc')); 1577 1599 } 1578 1600 $this->feed_url = $file->url; 1579 1601 } … … 2962 2984 } 2963 2985 2964 2986 /** 2987 * Set the favicon handler 2988 * 2989 * @deprecated Use your own favicon handling instead 2990 */ 2991 public function set_favicon_handler($page = false, $qs = 'i') 2992 { 2993 $level = defined('E_USER_DEPRECATED') ? E_USER_DEPRECATED : E_USER_WARNING; 2994 trigger_error('Favicon handling has been removed, please use your own handling', $level); 2995 return false; 2996 } 2997 2998 /** 2999 * Get the favicon for the current feed 3000 * 3001 * @deprecated Use your own favicon handling instead 3002 */ 3003 public function get_favicon() 3004 { 3005 $level = defined('E_USER_DEPRECATED') ? E_USER_DEPRECATED : E_USER_WARNING; 3006 trigger_error('Favicon handling has been removed, please use your own handling', $level); 3007 3008 if (($url = $this->get_link()) !== null) 3009 { 3010 return 'http://g.etfv.co/' . urlencode($url); 3011 } 3012 3013 return false; 3014 } 3015 3016 /** 3017 * Magic method handler 3018 * 3019 * @param string $method Method name 3020 * @param array $args Arguments to the method 3021 * @return mixed 3022 */ 3023 public function __call($method, $args) 3024 { 3025 if (strpos($method, 'subscribe_') === 0) 3026 { 3027 $level = defined('E_USER_DEPRECATED') ? E_USER_DEPRECATED : E_USER_WARNING; 3028 trigger_error('subscribe_*() has been deprecated, implement the callback yourself', $level); 3029 return ''; 3030 } 3031 if ($method === 'enable_xml_dump') 3032 { 3033 $level = defined('E_USER_DEPRECATED') ? E_USER_DEPRECATED : E_USER_WARNING; 3034 trigger_error('enable_xml_dump() has been deprecated, use get_raw_data() instead', $level); 3035 return false; 3036 } 3037 3038 $class = get_class($this); 3039 $trace = debug_backtrace(); 3040 $file = $trace[0]['file']; 3041 $line = $trace[0]['line']; 3042 trigger_error("Call to undefined method $class::$method() in $file on line $line", E_USER_ERROR); 3043 } 3044 3045 /** 2965 3046 * Sorting callback for items 2966 3047 * 2967 3048 * @access private