From d84972e1a62885c1e3f4d87e4edef2f1a82be30d Mon Sep 17 00:00:00 2001 From: Fabien Potencier Date: Sun, 28 Mar 2010 09:49:09 +0200 Subject: [PATCH] added a note about variable resolution and PHP4-style constructors (refs #33) --- doc/02-Twig-for-Template-Designers.markdown | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/doc/02-Twig-for-Template-Designers.markdown b/doc/02-Twig-for-Template-Designers.markdown index 93d35ff..134c902 100644 --- a/doc/02-Twig-for-Template-Designers.markdown +++ b/doc/02-Twig-for-Template-Designers.markdown @@ -72,7 +72,8 @@ If a variable or attribute does not exist you will get back a `null` value > > * check if `foo` is an array and `bar` a valid element; > * if not, and if `foo` is an object, check that `bar` is a valid property; -> * if not, and if `foo` is an object, check that `bar` is a valid method; +> * if not, and if `foo` is an object, check that `bar` is a valid method +> (even if `bar` is the constructor - use `__construct()` instead); > * if not, and if `foo` is an object, check that `getBar` is a valid method; > * if not, return a `null` value. > -- 1.7.2.5