title: How to Track Facebook Social Plugin (Like/Recommend) using FB.Event.Subscribe (edge.create)
body: <p>I'm using the Facebook Social Plugin for the Like/Recommend button. I'm testing it on the following page: </p>
  
  <p><a href="http://christopherbush.co.uk/igk/share-test.php" rel="nofollow">http://christopherbush.co.uk/igk/share-test.php</a></p>
  
  <p>The button is programmed to like a specific page (ivegotkids.com) and that works perfectly. I've added the Meta Tags so the correct information is posted on Facebook when a person clicks on the button. All I need to do now is add tracking so the name of the person who has clicked it can be stored in my database.</p>
  
  <p>Facebook says that you can do this using the Event.Subscribe function but their only example tells you how to display an alert... I don't want to display an alert. I want to grab the person's name and deposit it into my database so I can check who has liked the page and who hasn't. </p>
  
  <p>Here is what I have so far: </p>
  
  <pre><code>&lt;?php // Adds the Facebook Javascript SDK ?&gt;
  &lt;div id="fb-root"&gt;&lt;/div&gt;
  &lt;script&gt;(function(d, s, id) {
    var js, fjs = d.getElementsByTagName(s)[0];
    if (d.getElementById(id)) {return;}
    js = d.createElement(s); js.id = id;
    js.src = "//connect.facebook.net/en_GB/all.js#xfbml=1";
    fjs.parentNode.insertBefore(js, fjs);
  }(document, 'script', 'facebook-jssdk'));&lt;/script&gt;
  
  
  
  
  &lt;?php // Adds the Facebook "Like" Button ?&gt;
  &lt;fb:like href="http://ivegotkids.com" send="false" width="450" show_faces="true" action="recommend" font="trebuchet ms"&gt;&lt;/fb:like&gt;
  
  
  
  
  &lt;?php // Adds the Facebook Tracking Code ?&gt;
  
  
  &lt;script&gt;
  FB.Event.subscribe('edge.create',
  
      function(response) {
  
  
          alert('You Recommended: ' + response);
  
  
      }
  );
  &lt;/script&gt;
  </code></pre>
  
  <p>I need to change the "alert" line to whatever it is I'm missing... This is where I should be putting my tracking code but I just cannot find any examples of what I can put there to do what I want.</p>