Reasons - Why Prestashop has chosen Smarty?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Tom Evans
    Junior Member
    • Apr 2014
    • 22

    Reasons - Why Prestashop has chosen Smarty?

    There are many benefits that why Prestashop has chosen Smarty. Two of the most important are;

    1. Security.
    2. Easy to Use and Maintain.

    The way Prestashop uses the .tpl files all you need to do is go to modules/homefeatured, open the tpl file, find this line:
    {$product.description_short|strip_tags:htmlall:'UT F-8'|truncate:130}
    and simply change 130 to something smaller, say 90 and that it, the description on each product displayed in thsi module is now 90 characters long - no risk of you creating any syntax errors in php.
    So Smarty gives more flexibility to designers even for those who are not PHP developers.

    A few things that you should expressly avoid when using Smarty:
    1. Do not make direct call PrestaShop's constants. Most particularly, do not even use {$smarty.const._DB_P***WD_}, for obvious reasons.
    2. Do not override PrestaShop's ***igned variables.
    3. Do not make the code needlessly hard to read. For instance, refrain from making include calls from within an already included file.
    4. Do not make direct PHP calls. For instance, do not use {php} // PHP code {/php}'
    Ready to Take PrestaShop to the Next Level....
Working...
😀
😂
🥰
😘
🤢
😎
😞
😡
👍
👎