Questions about smarty-php Tutorial

Source: Internet
Author: User
New users ask questions about smarty! I don't know if you still remember that I was called by the leaders to learn PHP. I 've been learning about the situation for nearly a month, but I am still confused about the smarty issue: you can understand that a template file is a static page and add all the things that need to be dynamic; however, the subsequent steps won't work. do you still need to call another file dynamically? Do you still need to configure it? How to learn ------ solution -------------- The new user asks the question of smarty!
I don't know. you still remember that I was called by the leaders to learn PHP. I 've been learning about the situation for almost a month, and I am still confused.
Questions about smarty:
You can understand that a template file is a static page and add all the things that need to be dynamic;
But the subsequent steps won't.
Is it necessary to call another file dynamically? Do you still need to configure it? How to Learn

------ Solution --------------------
Smarty is a template engine. after adding smarty to a static page. Php is required to load the template. Then, pay the value of the corresponding variable in php to the template. Then, make a dynamic call in the template.

I don't know if you can understand what I said!
------ Solution --------------------
We recommend that you check the smarty manual. There are related examples on the internet. let's take a look.
------ Solution --------------------
1. variable $ a defined in php;
2. assign the variable $ a to the template variable AAA;
$ Smarty-> assign ("AAA", $ );
3. page call Template variables

{$ AAA}


Step 2 may be called on different pages. if you recognize these three parts, then K. O.
------ Solution --------------------
Guy, do you want to use smarty or uchome. Uchome does not use the template engine written by smarty.
The general usage of smarty provides demos. A website is also searched here:
Http://wenku.baidu.com/view/b884a1d428ea81c758f57804.html
Http://www.beyond-x.net /? Post = 6

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.