]> git.mxchange.org Git - friendica.git/blobdiff - include/Scrape.php
how the heck did favicon get into the repo? Gone now...
[friendica.git] / include / Scrape.php
index 1a9c03c8eccb99adc362b0a8a674552e8906b19a..698ec9cf04c4e182ecefd98752b7d645a48215ed 100644 (file)
@@ -423,7 +423,7 @@ function probe_url($url) {
                                $poll = $tapi . '?user_id=' . $tid;
                        else
                                $poll = $tapi . '?screen_name=' . $tid;
-                       $profile = 'http://twitter.com/!#/' . $tid;
+                       $profile = 'http://twitter.com/#!/' . $tid;
                }
 
                if(! x($vcard,'fn'))
@@ -442,13 +442,20 @@ function probe_url($url) {
 
                        if(x($feedret,'photo'))
                                $vcard['photo'] = $feedret['photo'];
-                       require_once('simplepie/simplepie.inc');
+                       require_once('library/simplepie/simplepie.inc');
                    $feed = new SimplePie();
                        $xml = fetch_url($poll);
 
+                       logger('probe_url: fetch feed: ' . $poll . ' returns: ' . $xml, LOGGER_DATA);
+                       $a = get_app();
+
+                       logger('probe_url: scrape_feed: headers: ' . $a->get_curl_headers(), $LOGGER_DATA);
+
                        $feed->set_raw_data($xml);
 
                    $feed->init();
+                       if($feed->error())
+                               logger('probe_url: scrape_feed: Error parsing XML: ' . $feed->error());
 
                        if(! x($vcard,'photo'))
                                $vcard['photo'] = $feed->get_image_url();