thinkphp模板中使用函数的方法
时间:2014-08-20 18:12:53
收藏:0
阅读:324
1、执行函数并输出返回值:
格式:{:function(…)}
例如,输出U函数的返回值:
{:U(‘User/insert‘)}
编译后的PHP代码是
<?php echo U(‘User/insert‘);?>
格式:{~function(…)}
例如,调用say_hello函数:
{~say_hello(‘ThinkPHP‘)}
编译后的PHP代码是:
<?php say_hello(‘ThinkPHP‘);?>
thinkphp模板中使用函数的方法,布布扣,bubuko.com
原文:http://my.oschina.net/guomingliang/blog/304804
评论(0)