]> git.wh0rd.org Git - tt-rss.git/commitdiff
remove simplepie entity decode hacks
authorAndrew Dolgov <fox@fakecake.org>
Wed, 1 May 2013 14:06:53 +0000 (18:06 +0400)
committerAndrew Dolgov <fox@fakecake.org>
Wed, 1 May 2013 14:07:05 +0000 (18:07 +0400)
include/rssfuncs.php

index 21040e5a78d7fc2bb276c2a11492f6b129ac7d9e..9148cc0e08111858cb5974175b21ed4e4ad77d1a 100644 (file)
 
                                _debug("date $entry_timestamp [$entry_timestamp_fmt]", $debug_enabled);
 
-                               $entry_title = html_entity_decode($item->get_title(), ENT_COMPAT, 'UTF-8');
-                               $entry_title = decode_numeric_entities($entry_title);
+//                             $entry_title = html_entity_decode($item->get_title(), ENT_COMPAT, 'UTF-8');
+//                             $entry_title = decode_numeric_entities($entry_title);
+                               $entry_title = $item->get_title();
 
                                $entry_link = rewrite_relative_url($site_url, $item->get_link());
 
 
                _debug("Cleaned $rc cached tags.");
        }
-
-       function utf8_entity_decode($entity){
-               $convmap = array(0x0, 0x10000, 0, 0xfffff);
-               return mb_decode_numericentity($entity, $convmap, 'UTF-8');
-       }
-
-       function decode_numeric_entities($body) {
-               $body = preg_replace('/&#\d{2,5};/ue', "utf8_entity_decode('$0')", $body );
-               $body = preg_replace('/&#x([a-fA-F0-7]{2,8});/ue', "utf8_entity_decode('&#'.hexdec('$1').';')", $body );
-               return $body;
-       }
 ?>