<?php
namespace Parser;
use Router;
use Uri;
use Twig_Extension;
use Twig_Function_Function;
use Twig_Function_Method;
class Twig_Fuel_Extension extends Twig_Extension
{
public function getName()
{
return 'fuel';
}
public function getFunctions()
{
return array(
[b]'fuel_*_*' => new Twig_Function_Method($this, 'call_static_method'),[/b]
);
}
[b]
public function call_static_method($object, $method)
{
$args = func_get_args();
array_shift($args);
array_shift($args);
return call_user_func_array(array($object, $method), $args);
}
[/b]
}
It looks like you're new here. If you want to get involved, click one of these buttons!