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

Overload $Smarty->assign(), Hints?

 
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 -> Plugins
View previous topic :: View next topic  
Author Message
bsmither
Smarty Elite


Joined: 20 Dec 2011
Posts: 322
Location: West Coast

PostPosted: Sat Dec 31, 2016 3:31 am    Post subject: Overload $Smarty->assign(), Hints? Reply with quote

I am wanting to do this:
Code:
$Smarty->assign(String $name, Mixed $val, [options, ...])

where the options are anything I want to do.

Specifically:
Code:
$Smarty->assign(String $name, Mixed $val, nodebug)

The specific example will, at some point in compiling the template with the {debug} function in it, remove (or skip over) that template variable from the collection of template variables when rendering the debug template.

Any hints?
Back to top
View user's profile Send private message
AnrDaemon
Administrator


Joined: 03 Dec 2012
Posts: 1785

PostPosted: Sat Dec 31, 2016 5:32 pm    Post subject: Reply with quote

Hint: Don't do that.

It will, inevitable, confuse you and anyone else trying to debug the template.
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 -> Plugins 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