AOL Contact List Grabber (Address Book Import)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • naved
    New Member
    • Dec 2006
    • 2

    AOL Contact List Grabber (Address Book Import)

    Hi,

    I am desparately looking for a solution for importing address book from aol webmail to my browser. I found some commercial solution (such as, http://svetlozar.net) which was done using cURL. But couldnt find any php classes to implement it. Anyone can help me how to implement this ?

    Thanks in advance

    Naved
  • naved
    New Member
    • Dec 2006
    • 2

    #2
    Just a while ago i found this code from cURL mailing list for loggin into aol

    [PHP]
    $login = 'abcd';
    $pass = '1234';

    $url = "https://my.screenname.a ol.com/_cqr/login/login.psp";
    $user_agent = "Mozilla/4.0 (compatible; MSIE 5.01; Windows NT 5.0)";
    $postvars = "screenname=".$ login."&passwor d=".$pass."&sub mitSwitch=1&sit eId=aolcomprod& mcState=initial ized&authLev=1" ;
    $cookie = "cookies/test";
    @unlink($cookie );

    $ch = curl_init($url) ;
    curl_setopt($ch , CURLOPT_USERAGE NT, $user_agent);
    curl_setopt($ch , CURLOPT_SSL_VER IFYPEER, 1);
    curl_setopt($ch , CURLOPT_CAINFO, "E:/aol_grab/curl-ca-bundle.crt");
    curl_setopt($ch , CURLOPT_HEADER, 1);
    curl_setopt($ch , CURLOPT_POST, 1);
    curl_setopt($ch , CURLOPT_POSTFIE LDS, $postvars);
    curl_setopt($ch , CURLOPT_COOKIEJ AR, $cookie);
    curl_setopt($ch , CURLOPT_FOLLOWL OCATION, 1);
    curl_setopt($ch , CURLOPT_RETURNT RANSFER, 1);
    $content = curl_exec ($ch);
    file_get_conten ts("http://d02.webmail.aol .com/22250/aol/en-us/Suite.aspx");
    //print_r(curl_ge tinfo($ch));
    //echo "\n\ncURL error number:" .curl_errno($ch );
    //echo "\n\ncURL error:" . curl_error($ch) ;
    curl_close ($ch);
    unset($ch);
    echo "<PRE>".htmlent ities($content) ;
    [/PHP]

    and I was able to log in to it successfully..t he output is as below
    [HTML]
    <pre>HTTP/1.0 200 OK
    Date: Wed, 20 Dec 2006 09:31:47 GMT
    Server: Apache
    Pragma: No-cache
    Expires: Thu, 01 Jan 1970 00:00:00 GMT
    Set-Cookie: RSP_COOKIE=type =23&amp;name=SX FiYWxuYXZlZA%3D %3D&amp;stype=1 00; Domain=.aol.com ; Expires=Sat, 15-Dec-2007 09:31:47 GMT; Path=/
    Set-Cookie: SNS_TT=AAppcWJh bG5hdmVkRYkDAwA AEAABADzZgUOA2m d9Z10eZXKIoglrj oCeCrbwVT0pwLi4 eVd8mDKn%2BVKco %2FRRi%2F5rNTsm 5vMgc1UlyzEDQ%2 BXxYeQ%3D; Domain=my.scree nname.aol.com; Expires=Fri, 19-Jan-2007 09:31:47 GMT; Path=/
    Set-Cookie: MC_CMP_ESK=NonS ense; Domain=.aol.com ; Path=/
    Set-Cookie: SNS_SKWAT=diAyL jAga2lkIDEgdDF5 SDJxYmROcHhxN0F HbEh6V1hDMmJLc0 djPQ%3D%3D-b0o7Q4xCU%2F39I ESbtoTm9mBdSL47 fxxUnmD4X1Pn82% 2Fol%2B03%2BtxO LynThOHeQsaL5xd merZnzZT34sulbm tlrezipaPLkGMHi XQBbDQpCZb53AT7 EPRZ2sWEvYfeP0a 9rf%2FDn%2F2ER3 2h0rLA5%2B7UMs6 NmHharvEJQCFkTV YUHyjUa6btTL8tw XF4JmsiXUX0uXBu OHibk6Pl9lKtKJj 779U%2BiXUU4oBi Spcg6Q%2FYKJUvG Nsk4cjDURDglR9S sQL0iCJ2S1w4YGA %3D; Domain=screenna me.aol.com ; Path=/
    Set-Cookie: SNS_SC=diAxLjAg a2lkIDEgQ2R1RXN SeDJGTDZ3SmNNMX RkMUthQ25kdEhZP Q%3D%3D-dwYGM2lmn8IsM5q bIMCD4cF876hxn2 8LVqa2CrLuSNY%2 FClN58OIf%2Bg1G bhwkQ8c4%2BoZTQ gtZjkKb0gS4x9xI 2v1HzzyBQU7%2FU GAuyvgR9SWpqJmj zOpUJldJIJHA43W wgahRfwXBKCp8Ci B%2FPMLCa4bSsNd pgaEVUgc%2FrdXC OOU%3D; Domain=my.scree nname.aol.com; Path=/
    Set-Cookie: SNS_L0=diAxLjAg a2lkIDEgUUpsdVV rUWtzb21SOFhPdG o1SFo2R2swQzJzP Q%3D%3D-RgHJcTIzyWP%2BQ Ib7S6lE%2BpdmQv 1XVmfP; Domain=screenna me.aol.com ; Expires=Tue, 15-Jul-2036 09:31:47 GMT; Path=/
    Set-Cookie: SNS_LDC=1 aolcomprod 1 1166607107 0 1166607107 0; Domain=my.scree nname.aol.com; Expires=Fri, 19-Jan-2007 09:31:47 GMT; Path=/
    Set-Cookie: SNS_AA=asrc=2&a mp;sst=11666071 07; Domain=.aol.com ; Path=/
    P3P: CP="PHY ONL PRE STA CURi OUR IND"
    Content-length: 1505
    Cache-control: no-cache
    Content-language: en-US
    Content-type: text/html;charset=ut f-8
    Connection: close






















    &lt;html&gt;&lt ;head&gt;&lt;ti tle&gt;Scr
    [/HTML]

    But i dont know how to fetch the email addresses from the contact list. Any one can help me on this ?

    Thanks in Advance

    Comment

    Working...