User Tools

Site Tools


designers:no_use_php

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
designers:no_use_php [2011/09/09 17:08]
jonyo created
designers:no_use_php [2014/09/25 16:55] (current)
Line 1: Line 1:
 ====== Alternatives for {php} In Templates ====== ====== Alternatives for {php} In Templates ======
  
-Use of the **{php}** in Smarty templates is deprecated and should not be used, as going forward in future versions of Smarty they may no longer work.  Starting in **version 6.0.0** which uses Smarty 3.0, you will need to specifically turn on use of {php} in the admin at **Design > Template Sets**.+Use of the **{php}** in Smarty templates is removed and should not be used, as going forward starting in Smarty 3.1 they will no longer work.  Starting in **version 6.0.0** which uses Smarty 3.1.5, you will no longer be able to use {php} Smarty tags and must use an alternate resource instead.  More info can be read in the [[http://smarty-php.googlecode.com/svn/trunk/distribution/SMARTY_3.1_NOTES.txt|Smarty 3.1 Release Notes]].  Here is a snippet from that specifically affecting the {php} (and related) functions:
  
-You can read more info about it on the [[http://www.smarty.net/docs/en/language.function.php.tpl|smarty.net documentation page for {php}]].  Below are alternatives to using {php} in your templates specific for this software.+  There is absolutely no PHP allowed in templates any more. All 
 +  deprecated features of Smarty 2.0 are goneAgain, use the SmartyBC 
 +  class if you need any backward compatibility.
  
-  * Use an Addon Tag instead, or use one of the other tools available to addons in the software. +You can also read more info about it on the [[http://www.smarty.net/docs/en/language.function.php.tpl|smarty.net documentation page for {php}]].  Below are alternatives to using **{php}** in your templates specific for this software. 
-  * Create a smarty plugin.+ 
 +  * Use an Addon Tag instead, or use one of the other tools available to addons in the software.  As of **Version 6.0.0**, all addon tags are called **on the fly**, with the $params and $smarty vars passed to the tag methods.  For addon developers, this means you now have same abilities as you would if you created a custom smarty plugin!  See the smarty.net documentation for [[http://www.smarty.net/docs/en/plugins.functions.tpl|Plugin Functions]] for more info
 +  * Create a custom smarty plugin.  See the [[http://www.smarty.net/docs/en/plugins.functions.tpl|smarty.net documentation]] for more info.
designers/no_use_php.1315588124.txt.gz · Last modified: 2014/09/25 16:55 (external edit)