How to apply event tracking with multiple piwik server?

we use below script code for multiple piwik server,

but I don’t know how to track the events in the html page.

for example, I use like this code…

<\a href=“A1.html” onClick=“javascript:ccTracker1.trackEvent(‘category1’, ‘plan_page’, ‘Action_A1’);”>Action_A1.html

but, it doesn’t work, please give me any idea?

thank you so much…

window.piwikAsyncInit = function () {
    try {
        var ccTracker1 = Piwik.getTracker("//url_1/piwik.php", 1);
		var ccTracker2 = Piwikc.getTracker("//url_2/piwik.php", 2);
    } catch( err ) {}
(function() {
	var c="//url1/";
	var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
	g.type='text/javascript'; g.async=true; g.defer=true; g.src=c+'piwik.js'; s.parentNode.insertBefore(g,s);

Hi there,

I recommend you upgrade to our latest Piwik 2.16.2 beta version: I would like to test early beta and RC releases, how do I enable automatic updates to use these development versions? - Analytics Platform - Piwik

where we have already implemented a better system to track data into multiple trackers, see the new documentation at: Document the new addTracker functionnality by mattab · Pull Request #132 · matomo-org/developer-documentation · GitHub