WordPress.org

Support

Support » Plugins and Hacks » [Plugin: Social Media Widget] Using Google Analytics Event Code

[Plugin: Social Media Widget] Using Google Analytics Event Code

  • ontargetpro
    Member

    @ontargetpro

    Love the plugin. In fact I use it twice on my blogs – one for social sites, one for review sites.

    I’m trying to get better about tracking goals and events with Google Analytics. Is there a way to incorporate event tracking code here?

    This is what my event tracking link looks like for keeping track of those clicking to subscribe to my Email newsletter:

    <a href="http://bit.ly/KsCL78" onClick="_gaq.push(['_trackEvent', 'Email Signup', 'Email Signup Click', 'Clicked', 50, true]);">Get our Email Newsletters.</a>

    Might be asking too much, but figured I’d try!

    http://wordpress.org/extend/plugins/social-media-widget/

Viewing 1 replies (of 1 total)
  • brianfreytag
    Member

    @brianfreytag

    This actually isn’t a terrible idea, but I’m not sure how I might include this is my widget. The obvious thought is to include an “onClick” event input box, but I can foresee this being used for evil instead of good (security issues).

    I’ll think on this issue and read into security issues that might arise by allowing onClick javascripts in my widget.

    Thanks for the suggestion,

    Brian

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Social Media Widget] Using Google Analytics Event Code’ is closed to new replies.