On 05-08-2010 at 20:44:45 Bas Kooij <kooy...@hotmail.com> wrote:

My current templates looks like this:

FILE main.xhtml:

<html metal:define-macro="main">
    <tal:block metal:define-slot="page" />

FILE home.xhtml:

<tal:block metal:use-macro="main.xhtml/main">
    <tal:block metal:fill-slot="page">

        <tal:block metal:use-macro="customMacro" />


I have a custom SourceResolver like this:

class MySourceResolver implements PHPTAL_SourceResolver {
    public function resolve($path) {
        echo $path;

However, this SourceResolver only echo's the path 'home.xhtml', I never get the vaule ´customMacro´. Am I doing something wrong here, or is this impossible or a

I tried the latest beta too btw, with the same results.

That's by design. Resolver just needs to find the file, and PHPTAL will then look for the macro in it.

regards, Kornel

PHPTAL mailing list

Reply via email to