many thanks,

does the job i want

gernot

-----Urspr�ngliche Nachricht-----
Von: Andy Wardley [mailto:[EMAIL PROTECTED]]
Gesendet: Montag, 09. Dezember 2002 19:29
An: Gernot Homma
Cc: [EMAIL PROTECTED]
Betreff: Re: [Templates] BLOCKS directive points to method of an object
?


Gernot Homma wrote:
>    $self->{__template} = new Template({
>       INCLUDE_PATH => '/mydir',
>       BLOCKS => {
>          'mysub1' => ??? # this should be something that points to mysub1

You could do it using closures.

        BLOCKS => {
            mysub1 => sub { $self->mysub1(@_) }
        }

HTH

A

_______________________________________________
templates mailing list
[EMAIL PROTECTED]
http://lists.ourshack.com/mailman/listinfo/templates

Reply via email to