|
|
|
|
@ -148,7 +148,7 @@ class Html extends Formatter {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public static function template(array $context = array(), $template = 'layout') {
|
|
|
|
|
$html = file_get_contents(sprintf('templates/%s.html', $template));
|
|
|
|
|
$html = file_get_contents(realpath(__DIR__ . '/../../../') . sprintf('/templates/%s.html', $template));
|
|
|
|
|
|
|
|
|
|
$patterns = array_map(function($p) { return "{{ $p }}"; }, array_keys($context));
|
|
|
|
|
return str_replace($patterns, array_values($context), $html);
|
|
|
|
|
|