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

Php notice with !empty and unassigned variable

 
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 -> Bugs
View previous topic :: View next topic  
Author Message
P@t
Smarty Rookie


Joined: 05 Dec 2010
Posts: 6

PostPosted: Sun Dec 05, 2010 9:40 pm    Post subject: Php notice with !empty and unassigned variable Reply with quote

Hi,

Sometimes, I test my variables with !empty (instead of isset). It work fine with smarty 2, but I have php notice with smarty 3 when variable doesn't exist. Is it bug?

Example:
Code:
{if !empty($my_varible)}{$my_variable}{/if}
Back to top
View user's profile Send private message
U.Tews
Administrator


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

PostPosted: Sun Dec 05, 2010 10:16 pm    Post subject: Reply with quote

This was a bug. It's fixed in the SVN trunk now.
Back to top
View user's profile Send private message
P@t
Smarty Rookie


Joined: 05 Dec 2010
Posts: 6

PostPosted: Sun Dec 05, 2010 10:38 pm    Post subject: Reply with quote

Thanks!
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 -> Bugs 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