Solution to Smarty variable regulator failure

Source: Internet
Author: User
This article mainly introduces the solution to the failure of the Smarty variable regulator. It can be said that the record filing is triggered by a space, and I am depressed for half an hour. I would like to share it with you. For more information, see

This article mainly introduces the solution to the failure of the Smarty variable regulator. It can be said that the record filing is triggered by a space, and I am depressed for half an hour. I would like to share it with you. For more information, see

The variable regulator of Smarty is a good thing, and it has always been easy to use. It can be found that it doesn't work when I used the variable regulator yesterday.

The Code is as follows:


{$ Name | upper}


I carefully read the manual, read the smarty loading path, and checked it up and down for nearly an hour without finding the problem. The code will be deleted and re-written into a helpless dilemma.

The Code is as follows:

{$ Name | upper}

The result is good. It turns out that the variable must be directly followed by a vertical line, function name, and no space in the middle. Otherwise, the function of the variable regulator will become invalid. After a long time, it turned out to be caused by a space. It's not worth it !!!

It seems that the smarty program will be called later. Pay attention to the space issue ~, Other problems may also be caused by spaces, which are the least likely to be discovered.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.