"trackPageView" with anchor clicks doesn't work


#1

I tried to track an anchor click with:


onclick="javascript:piwikTracker.trackPageView('category_menu');"

and with


onclick="javascript:piwikTracker.setCustomUrl(baseURL + '#category_menu'); javascript:piwikTracker.trackPageView(document.title + ' / category_menu');"

I found both codes in this forum but both doesn’t track the clicks.
The general Piwik code is implemented over !