protected function addFilter_money()
{
$moneyFilter = new Twig_SimpleFilter('money', function ($amount) {
if (func_num_args() != 2) {
throw new Exception('the money modifier expects one parameter: the idSite.');
}
$idSite = func_get_args();
$idSite = $idSite[1];
return piwik_format_money($amount, $idSite);
});
$this->twig->addFilter($moneyFilter);
}