Ecmall template Parsing

Source: Internet
Author: User
For the templates provided by ecmall, many users may know that there are still many functions that cannot be implemented at all. Basically, it is not as powerful as Smarty, but I have tried to introduce smarty but it is not very successful. The reason is that the ecmall template is not simply a template, however, many other business logic is included in the parsing. Therefore,

For the templates provided by ecmall, many users may know that there are still many functions that cannot be implemented at all. Basically, it is not as powerful as Smarty, but I have tried to introduce smarty but it is not very successful. The reason is that the ecmall template is not simply a template, however, many other business logic is included in the parsing. Therefore,

For the templates provided by ecmall, many users may know that there are still many functions that cannot be implemented at all. Basically, it is not as powerful as Smarty, but I have tried to introduce smarty but it is not very successful. The reason is that the ecmall template is not simply a template, however, many other business logics are included in the parsing process. Therefore, the template of ecmall is replaced by smarty directly, which may cause great problems in the development of widgets.
Therefore, for the sake of flexibility, I have added two methods to the parsing class in the ecmall template, one is to directly solve the php code, php code can be directly written in the template. The second is custom function parsing. During the parsing of the ecmall template, the parsing of user-defined functions is added.
Zhuo Stream Application Network (http://www.360cd.cn/)-Professional Secondary Development of ecmall <无>
{Php} $ shopArea_app = new ShopArea (); $ shopArea_app-> debug (); {/php} The main function here is to directly use {function func = cut_str source = $ shop_area.name length = 200} to produce the value of {$ shop_area.name }. intercept {foreach from = $ shopArea_list item = s} {function func = cut_str source = $ s. name length = 200} {/foreach}

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.