Form Submission GA Event / Goal


Y.use('node', function() {
    Y.on('domready', function() {
        Y.all('.form-block').each(function(n) {
            var d = n.getData('block-json');
            d = Y.JSON.parse(d);
            n.one('form').on('submit',function() {
                _gaq.push(['_trackEvent', d.formName + ' Submission', 'Form Submission', 'Submit']);
            });
});
});
});
Want a Fast Server Like Mine?

GET VULTR!