当前位置:网站首页>CI框架如何集成Smarty模板
CI框架如何集成Smarty模板
2022-07-28 06:51:00 【51CTO】
一、下载Smarty模板和CI框架
1.https://codeigniter.org.cn/
2.Smarty官网https://www.smarty.net/
二、文件拷贝和扩展核心类库
1. 将下载下来的smarty-3.1.30(可以下载其他版本,原理一样)存放到application/libraries/目录下.
2. 在application/libraries目录下新建文件Cismarty.php,内容如下:
3. 在application/config的文件中新建smarty.php,内容如下:
4. 在入口文件创建'templates、cache、configs目录
5. 在application/config/下找到autoload.php文件
$autoload[‘libraries’] = array(‘cismarty’);
6. 在application/core目录下新建MY_Controller,内容如下
7. 新建控制器Test.php
8. 新建视图test
9. 配置完成.
边栏推荐
- Day112.尚医通:手机验证码登录功能
- QT 怎么删除布局里的所有控件?
- Puzzle (004.3) pattern puzzle
- 微信小程序----微信小程序浏览pdf文件
- The fourth phase (2021-2022) research on the implementation of cloud native technology in traditional industries - central state-owned enterprises was officially released
- One key switch circuit
- [event registration] cloud native technology exchange meetup, see you in Guangzhou on August 6
- leetcode/单词长度的最大乘积
- CAT1 4G+以太网开发板232数据通过4G模块TCP发到服务器
- What if the task manager is not fully displayed?
猜你喜欢

本人男,27岁技术经理,收入太高,心头慌得一比
![Redis of non relational database [detailed setup of redis cluster]](/img/0b/bd05fb91d17f6e0dc9f657a4047ccb.png)
Redis of non relational database [detailed setup of redis cluster]

OSPF comprehensive experiment (7.12)

Understanding of spark operator aggregatebykey

A group of South University students rely on science and technology to go to sea, with an annual income of 1billion

uniapp---- 获取当前位置的经纬度等信息的详细步骤(包含小程序)

tkMapper的使用-超详细

Prescan quick start to master the transportation elements in lesson 14, prescan

Melt cloud x chat, create a "stress free social" habitat with sound

Can‘t connect to server on ‘IP‘ (60)
随机推荐
JS candy xiaoxiaole game source code
Chairman tree review
ASP. Net core foundation V
Draw.io image saving path settings
How to build the protection system of class protection technology of 2022 series of ISO compliance (Part I)
JS cartoon English alphabet typing game source code
【13】 Adder: how to build a circuit like Lego (Part 1)?
(十三)基于51单片机的简单温度报警装置
ASP. Net core foundation IV
tkMapper的使用-超详细
2022牛客多校第一场解题报告
Kubernetes技术与架构(七)
An article to understand data warehouse: metadata classification, metadata management
How to write a JMeter script common to the test team
五张图看懂EMI电磁干扰的传播过程-方波陡峭程度对高频成分的影响,时序到频域频谱图形,波形形状对EMI辐射的影响。
File operation of QT
[Err] 1055 - Expression#2 of select list is not in GROUP BY clause and contains nonaggregated column
Usage of qmap
Opentsdb time series database
In the task manager, the CPU speed displayed is greater than its maximum speed [main frequency]