This is my first stackoverflow question. yay.
Ok. I am attempting to splittest or a/b test copy for a featured facebook like button by using google analytics:
_gaq.push(['_trackEvent', 'facebook', 'click', 'amazing copy that hypnotizes user into clicking like']);
All fine and dandy so far.
To reign in the like/unlikes I found this snippet:
<script type="text/javascript">
<!--
FB.Event.subscribe('edge.create', function(href, widget) { _gaq.push(['_trackEvent', 'facebook', 'click', 'amazing copy that hypnotizes user into clicking like']); });
FB.Event.subscribe('edge.remove', function(href, widget) { _gaq.push(['_trackEvent', 'facebook', 'click', 'amazing copy that hypnotizes user into clicking like']); });
-->
</script>
Ok, everyone is with me so far? Now this (in theory) will give me like and unlikes for the featured experimental like button, but it will ALSO send data on other like buttons on the page, correct?
The question is: How do I isolate the edge.create callback (or whatever) to only fire when the desired like-button is clicked? Is there parrameters or arguments I can pass to the fb.event.subscribe that will check if the 'liked' url is the desired facebook page, maybe? or maybe if the liked url differs from the domain?
I am a total newb with js, jquery, and anything beyond basic php, html, or css. please help! :P