I'm getting the following 3 errors:

Warning: simplexml_load_string() [function.simplexml-load-string]:
Entity: line 62: parser error : Entity 'copy' not defined in C:\wamp
\www\TTT1\includes\twitter.functions.php on line 96

Warning: simplexml_load_string() [function.simplexml-load-string]: <li
class="first">&copy; 2009 Twitter</li> in C:\wamp\www\TTT1\includes
\twitter.functions.php on line 96

Warning: simplexml_load_string() [function.simplexml-load-string]: ^
in C:\wamp\www\TTT1\includes\twitter.functions.php on line 96

Here's my code:

Function getFollowers($id, $login) {
    $url = "http://twitter.com/followers/ids.xml?user_id="; . $id;
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, $url);
    curl_setopt($ch, CURLOPT_VERBOSE, 1);
    curl_setopt($ch, CURLOPT_USERPWD, $login);
    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
    $result = curl_exec($ch);
    curl_close($ch);
    $xml = simplexml_load_string($result);    // Line 96
    $followers = array();
    Foreach ($xml->id as $id) {
        array_push($followers, $id);
    }
    return $followers;
}

Is this a problem on my end or is the xml document not loading
properly?  It seems to load fine in my browser, and sometimes it
works.  I'm even doing a rate-limit verification before calling this
function to make sure the user can do it.

What to do?

Reply via email to