<? require_once('class.GrabYahoo.php'); // Yahoo! Account Username $login = "christsealed1"; // Yahoo! Account Password $password = "christ1"; // Initializing Class $yahoo = new GrabYahoo; /* Setting the desired Service 1. addressbook => Used to grab Yahoo! Address Book 2. messenger => Used to grab Yahoo! Messenger List 3. newmail => Used to grab number of new Yahoo! mails 4. calendar => Used to grab Yahoo! Calendar entries */ $yahoo->service = "addressbook"; /* Set to true if HTTP proxy is required to browse net - Setting it to true will require to provide Proxy Host Name and Port number */ $yahoo->isUsingProxy = false; // Set the Proxy Host Name, isUsingProxy is set to true $yahoo->proxyHost = ""; // Set the Proxy Port Number $yahoo->proxyPort = ""; // Set the location to save the Cookie Jar File $yahoo->cookieJarPath = $_SERVER['DOCUMENT_ROOT'] . "/grabyahoo"; /* Execute the Service - Require to pass Yahoo! Account Username and Password */ $yahooList = $yahoo->execService($login, $password); // Printing the array generated by the Class dump($yahooList); /* Printing new mail status - True (1) if there is new mail(s) - False (0) if there is no new mail */ //$newMailStatus = $yahoo->getNewMailStatus(); //echo $newMailStatus; // Use this line to figure out any error generated during the process echo $yahoo->errorInfo; function dump($var) { echo "<pre>"; print_r($var); echo "</pre>"; } ?>