How to track Facebook-Like-Button (iFrame)


#1

Hi there!
I try to track the click on a facebook-like-button, but because it’s in a iFrame it’s not that easy…

I tried some diffrent ways, like overlaying the iFrame with a div, which was kind of ironic, 'cause it tracked all clicks within the div, but - of course - excluded the iFrame-Part! :confused:

I tried to use an extra function which is loaded with the “onload”-attribute in the iframe-tag, but this won’t work, too! :frowning:

Any ideas? Would be realy nice!

Thanks!
Klener


(Matthieu Aubry) #2

See the feature request: Add FAQ ./ doc to explain how to track clicks on facebook social plugins (like / share) · Issue #2644 · matomo-org/matomo · GitHub

you should use the facebook API and add a hook to call piwik when there is a click on like