Overwrite title/url

I do need to overwrite title and url on every hit based on some rules with dimensions (it is singlapage application with always the same title and URL). Is there some example how to do it? My idea was to make some plugin that would be hit when tracker is about to save data to DB, get the request, read the data and modify them with my rules

I just use the async API calls in the router. eg. In the router.js file I use:

_paq.push(['setDocumentTitle', "Page Title"]);
_paq.push(['trackPageView']);

The Javascript API docs spell it out pretty well - http://developer.piwik.org/guides/tracking-javascript-guide

I cannot use/modify javascript on site, i need to modify if afterwards on the piwik side.

I guess I don’t understand. You have access to the PHP of Piwik but not to the Javascript. Is that correct?

If so, I guess you could modify the PHP on the Piwik side to update the data before sending to the DB. Trouble is that if it’s a single page application there won’t be any differentiation when the data hits the Piwik server. You have to update the JS to get that data.