Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

Throw exception(not Notice) if variable undefined

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> General
View previous topic :: View next topic  
Author Message
grisevg
Smarty n00b


Joined: 26 May 2011
Posts: 3

PostPosted: Thu Dec 01, 2011 10:17 am    Post subject: Throw exception(not Notice) if variable undefined Reply with quote

Hi,
Is there a way to force Smarty 3 throw exceptions instead of notices?
In smarty 2 there was error_unassigned param, but looks like it's removed in v3.
Back to top
View user's profile Send private message
U.Tews
Administrator


Joined: 22 Nov 2006
Posts: 5068
Location: Hamburg / Germany

PostPosted: Thu Dec 01, 2011 1:14 pm    Post subject: Reply with quote

Smarty2 did not throw any exception at all.

error_unassigned was a property of the early Smarty3 versions.
Because of internal changes to improve speed it was not possible to use it any longer in 3.1.

In the next major version 3.2 a new approach will be introduced how undefined variables are handled. It will then possible to configure exceptions as one option.

But 3.2 is still a couple of weeks down the road....
Back to top
View user's profile Send private message
grisevg
Smarty n00b


Joined: 26 May 2011
Posts: 3

PostPosted: Thu Dec 01, 2011 3:15 pm    Post subject: Reply with quote

Thanks! Very Happy
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> General All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP