title: Fill form using facebook data
body: <p>I would like to allow users to press a button on my page that will autofill a form with their first name, last name, and e-mail address, provided that they are logged into Facebook. If they are not, then the Facebook login form should popup, allowing the user to login, and then the auto fill should take place. </p>
  
  <p>I have been messing around with this in the javascript test console. I know I will need to call the first_name, last_name, and email, but I'm not sure how to populate my form fields with this information.</p>
  
  <pre><code>FB.api(
        {
          method: 'fql.query',
          query: 'SELECT first_name, last_name, email FROM user WHERE uid=' + response.authResponse.userID
        },
  </code></pre>
  
  <p>I would like to do this in javascript. I need to create a function that will populate a form with this information on click. Any ideas?</p>