Re: [SMARTY-DEV] newline after object call.

From: Date: Mon, 23 May 2005 12:00:04 +0000
Subject: Re: [SMARTY-DEV] newline after object call.
References: 1  Groups: php.smarty.dev 
Request: Send a blank email to php-smarty-dev+get-2721@lists.php.net to get a copy of this message
On Thu, May 05, 2005 at 03:04:11PM +0200, Arpad Borsos wrote: > Hi. > Is there any reason why there is a newline after object calls? > I have something similar in my code: > > {admin->checkright right="templates"} <- here you have a newline (ater the closing '}'), why not remove this? > <?xml version="1.0" encoding="ISO-8859-1"?> > > the problem is that when the code is parsed a newline is inserted after > the object call which results in a xhtml error. > I can work around the problem by using assign. But that makes no sense > since my admin::checkright function does not return anything. > Looks like this behavior is hardcoded in the compilers > _compile_registered_object_tag function. But i cant see any reason for this. yes, newline handling in Smarty is unreasonably complex. but i doubt this will be changed ever in Smarty 2.6.x, due to compatibility reasons.

« previous php.smarty.dev (#2721) next »