惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

阮一峰的网络日志
阮一峰的网络日志
D
Darknet – Hacking Tools, Hacker News & Cyber Security
S
Schneier on Security
The Last Watchdog
The Last Watchdog
Cyberwarzone
Cyberwarzone
S
Securelist
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
C
Cyber Attacks, Cyber Crime and Cyber Security
L
Lohrmann on Cybersecurity
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 司徒正美
The Cloudflare Blog
V
V2EX
博客园_首页
博客园 - 聂微东
Vercel News
Vercel News
人人都是产品经理
人人都是产品经理
G
GRAHAM CLULEY
T
Tenable Blog
Last Week in AI
Last Week in AI
Y
Y Combinator Blog
L
LINUX DO - 最新话题
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
SecWiki News
SecWiki News
博客园 - 三生石上(FineUI控件)
S
Secure Thoughts
N
News | PayPal Newsroom
T
The Blog of Author Tim Ferriss
The GitHub Blog
The GitHub Blog
T
Troy Hunt's Blog
博客园 - 【当耐特】
Forbes - Security
Forbes - Security
H
Hacker News: Front Page
A
About on SuperTechFans
B
Blog RSS Feed
Engineering at Meta
Engineering at Meta
MongoDB | Blog
MongoDB | Blog
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
罗磊的独立博客
D
DataBreaches.Net
P
Privacy & Cybersecurity Law Blog
Schneier on Security
Schneier on Security
Application and Cybersecurity Blog
Application and Cybersecurity Blog
Google DeepMind News
Google DeepMind News
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
Jina AI
Jina AI
D
Docker
P
Proofpoint News Feed

博客园 - Cure

Oracle 查看哪个表被锁定,并获取对应的sessionID Yii框架常见问题汇总 Yii框架中安装srbac扩展方法 Yii框架中使用PHPExcel导出Excel文件 Yii框架中使用SRBAC作为权限管理模块时遇到的问题 文件名过长,无法删除的解决办法 SilverLight中显示上标,下标,平方 10 Websites To Download Free HTML/CSS Templates 经过两天的努力,终于写出了第一个android的helloword sqlplus 帮助无法显示问题的解决 COBOL中USAGE的用法 asp.net mvc开发项目的部署?? 初试asp.net mvc感受 临时搞两天VC,在VC里如何获取当前程序的名字和路径以及如何分割字符串 Ruby on rails开发从头来(五十九)- ActiveRecord基础(预加载子记录) Borland以2300万美元卖掉CodeGear开发工具部门 Ruby on rails开发从头来(五十八)- ActiveRecord基础(自关联) 下载安装了ubuntu 8.04,感觉很好很强大 项目管理工具Redmine + SubVersion + Apache + windows环境安装搭建
Yii框架中使用bootstrap
Cure · 2012-04-12 · via 博客园 - Cure

Yii是类似于ROR的一个快速开发框架,PHP编写,用起来比较顺手,bootstrap是一个css,js框架,可以用来快速建站,将两者结合在一起,

可以弥补美工的不足。下面是在Yii框架中使用bootstrap的简单步骤:

1.创建一个web项目并配置:

cmd中,定位到xampp下的php目录,并执行下面的语句:

E:\xampp\php>php e:\xampp\apache\htdocs\framework\yiic webapp e:\xampp\apache\ht

docs\TestBootstrap

这样就会创建一个名为TestBootstrap的项目

BootStrap for YiiExtension拷贝到TestBootstrapprotected\extensions目录下。

修改config目录下的main.php文件,'preload'=>array('log','bootstrap')等配置,完成后如下:

// preloading 'log' component

'preload'=>array('log','bootstrap'),

// autoloading model and component classes

'import'=>array(

'application.models.*',

'application.components.*',

),

'modules'=>array(

// uncomment the following to enable the Gii tool

'gii'=>array(

'class'=>'system.gii.GiiModule',

'password'=>'Enter Your Password Here',

         // If removed, Gii defaults to localhost only. Edit carefully to taste.

'ipFilters'=>array('127.0.0.1','::1'),

'generatorPaths'=>array(

'bootstrap.gii', // since 0.9.1

),

),

// application components

'components'=>array(

'user'=>array(

// enable cookie-based authentication

'allowAutoLogin'=>true,

),

'bootstrap'=>array(

'class'=>'ext.bootstrap.components.Bootstrap',

),