ThinkPHP uses includefile to introduce the template and does not execute dynamic content. how can this problem be solved?

Source: Internet
Author: User
ThinkPHP uses includefile to introduce the template, so the dynamic content is not executed. what should I do? I heard that the label is set for the variable. What should I do. Urgent. Online, includefile only integrates the specified template into the current template, just as you need to pass the required data to the current template. of course, the data required for the newly added template is provided by you, I don't know. I only know that ThinkPHP can use include file to introduce the template without executing dynamic content. what should I do?
I heard that the label is set for the variable. What should I do. Urgent. Online

------ Solution --------------------
Include file
Only integrates the specified template into the current template
Just as you need to pass the required data to the current template, you must provide the required data for the newly added template.

------ Solution --------------------
I don't know. I only know that I can.
------ Solution --------------------
Direct use of functions in the template
The template file also supports convenient methods for directly calling functions, without using template variables. There are two methods:
1. execute the function and output the returned value.
Format:
{: Function}
Example:
{: Say_hello ('thinkphp')} // say_hello () is a user-defined function.
The actual execution result is equivalent:
Echo say_hello ('thinkphp ');
?>
2. execute functions but do not output
Format:
{~ Function}
Example:
{~ Say_hello ('thinkphp')} // say_hello () is a user-defined function.
The actual execution result is equivalent:
Say_hello ('thinkphp ');
?>
The preceding two methods also support passing in template variables as function parameters.
--------------------------------
This is what 51dev said. I hope it will be useful to you. I have never tried it.
------ Solution --------------------
Negative comments on the meaning of the template.
Http://blog.csdn.net/binyao02123202/article/details/7240848

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.