Web form that asks for the user's Yahoo ID and password, queries Yahoo Mail for the user's address book, and then presents the user's contacts on the page in a form with checkboxes next to each. See [url removed, login to view] for an example of this type of function. Note that the function for the second form (the results of the import) does not need to be implemented, but the front end form does. The whole process should be transparent to the user, they just put in their id and password, hit submit, then see their contacts on the resulting page. The code must be PHP 5 using CURL, not fopen for fetching web pages. Any other libraries used must be freely available and stable. User's ID and password must only be sent to Yahoo's servers. No other servers should be queried in the process. ID and password must not be saved to any persistent data source (database, flat files, etc.). If we like your code, there will be followup work for you in importing contacts from other email services, as well as more involved GUI work.
1. HTML/PHP code for the first form. This form will have two fields, Yahoo ID and password, and a submit button. 2. A PHP function that takes a Yahoo ID and password, which fetches the user's address book and returns a PHP array containing that person's contacts. Each array element must have at least the contact's first name, last name, and email address, although other information may be included. This function must also return error codes for all reasonable errors: site is unreachable, parse error, incorrect password, etc. (Grabbing and parsing the user's contacts CSV file is probably the easiest way to do this, but if there's an easier way, go for it.) This function may call other helper functions. Code should be written for readability, maintainability, extensibility. 3. A form that presents each contact back to the user (first name, last name, email address) along with a checkbox next to each contact and a submit button. Or an error message if the import function returned an error. The POST action for this button need not be implemented, but leave a hook into the code for us to fill in.
PHP 5 on Linux.