Re: [SMARTY] Class::method() in if tags

From: Date: Mon, 08 Mar 2004 15:22:34 +0000
Subject: Re: [SMARTY] Class::method() in if tags
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-11074@lists.php.net to get a copy of this message
David Förster wrote:
Hello, {if Auth::logged_in()} produces Fatal error: Smarty: [in main.tpl line 115]: syntax error: unidentified token '::logged_in()' Can I use a different syntax or are there any plans to support that in the future?
Hi, I posted a related question about that I would like to use dereferenced syntax (PHP5) e.g. {$Field->getValue()->getName()} does anyone have any pointers (maybe tips onchanging the rather long regexps that are used to parse the templates*), maybe one of the smarty developers has some insight regarding possible future support of the dereferenced/static object syntax? *I haven't had much success in trying to change the 1000+ char regexp that is used to indentify/parse PHP 'object'-related expressions. rgds, Jochem ps - sorry for reposting but I am really in need of a pointer or to know whether there is any intention to support the above mentioned. I had the idea that maybe my last post was not well understood (or it just silently fell off the radar, so to speak... these things happen ;-) pps - just out of interest, do the regexps used to parse the templates really need to be so long? my first impression was 'its got to be possible to do that more consisely' - I atleast assumed that Smarty has a potential performance gain to be had by optimizing these regexps. I was quite amazed by the size!

« previous php.smarty.general (#11074) next »