1

I've also posted this on the Piwik Forums but have gotten no response.

Piwik Forum Post

Piwik is up and running fine, the tracking code is on every page included in the footer. I'm trying to use the Goal feature and thus want to manually trigger it using onclick. Here is the code I have in my page. It's exactly as shown in their examples.

<input type="submit" value="Submit Request" class="button" 
       onclick="piwikTracker.trackGoal(1);" />

However when I click it Piwik does not register it as a Goal. I tried replacing the piwikTracker stuff with "return false" and the button becomes inactive so I know the javascript is working.

1 Answer 1

0

Have you set up a goal in Piwik? If you set up a goal in Piwk the code should work, just use the following settings:

enter image description here

Make sure you also use the right goal number, that sometiems can slip you up as well.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.