PHP模版引擎 Templum

码农软件 · 软件分类 · 模板引擎 · 2019-08-25 09:44:36

软件介绍

Templum 是一个超轻量级的、高速的而且功能强大的 PHP 模版引擎,它重用了 PHP 本身的强大功能,提供了附加的特性以简化模版的编写。

示例模版:

[[
if (!function_exists('helperBtnAction')) {
function helperBtnAction($action, $id, $icon) {
echo('<a target="_blank" rel="nofollow" href="?action='.$action.'&id='.$id.'">');
echo('<img src="ico/'.$icon.'.png" alt="'.$icon.'" border="0" />');
echo('</a>');
};
};
]]

<h1>User list</h1>

<p>Hello {{$username}}, here's a list of all the users:</p>

<div id="acocunts">
@if (count($accounts) <= 0):
No accounts found.
@else:
<table>
<tr>
<th>&nbsp;</th>
<th>Username</th>
<th>Full naam</th>
</tr>
@foreach ($accounts as $account):
<tr>
<td>{{helperBtnAction('account.edit', $account['id'], 'edit')}}</td>
<td>{{$account['username']}}</td>
<td>{{$account['realname']}}</td>
</tr>
@endforeach
<tr>
<td>{{helperBtnAction('account.add', '', 'add')}}</td>
<td colspan="4">&nbsp;</td>
</tr>
</table>
@endif
</div>

本文地址:https://codercto.com/soft/d/13123.html

xHTML+CSS+Dreamweaver CS3标准网站构建实例详解

xHTML+CSS+Dreamweaver CS3标准网站构建实例详解

李晓斌 / 第1版 (2007年9月1日) / 2007-9 / 49.9

《xHTML+CSS+Dreamweaver CS3标准网站构建实例详解》特别适合网站美工、网站前端架构师、网页设计爱好者、Wap页面设计师作为学习Web标准网页制作的入门图书,也适合Web标准网站高手作为案头随手查询手册,也适合作为美术院校和培训学校相关专业的培训教材。一起来看看 《xHTML+CSS+Dreamweaver CS3标准网站构建实例详解》 这本书的介绍吧!

SHA 加密
SHA 加密

SHA 加密工具

正则表达式在线测试
正则表达式在线测试

正则表达式在线测试

HSV CMYK 转换工具
HSV CMYK 转换工具

HSV CMYK互换工具