CodeIgniter框架的下载及安装,codeigniter框架
CodeIgniter 是一套给 PHP 网站开发者使用的应用程序开发框架和工具包。初次学习Php,网上搜了很多php框架,最后选择了CodeIgniter。下面向码农介绍CodeIgniter框架的下载及安装。
安装环境:php5+mysql6.5+iis7
我的电脑是用来办公写文档用的,win7系统,不想换系统,所以就安装了win7自带的iis7.
php下载的是最新的php-5.3.28-nts-Win32-VC9-x86
mysql也是下载最新的。
下载地址:
php:http://windows.php.net/downloads/releases/
mysql:http://dev.mysql.com/downloads/mysql/
CodeIgniter:http://codeigniter.org.cn/
当然,我是在windows环境下配置,需要下载windows 下的相关版本的软件,如果是linux等,需要下载该系统下支持的软件。
好啦,不多说了,咱开始安装吧,安装完一步一步探索。首先说,我是新手,有很多说的不对的地方请指正,我现在主要工作非IT,不常更新,偶尔休憩,看书。
第一步:下载下来codeigniter,是一个压缩包。解压后如下图:
主要有这3个文件,application文件夹是应用文件夹,里面主要有MVC相关的M-模型文件夹,
V-视图文件夹,C-控制器文件夹,还有一些配置文件,后面会讲到。
system文件件,是系统文件夹,CI (CodeIgniter)的核心文件。
user_guide 即离线的用户帮助文档,便于查询。不过都是英文的哦,英文不好的童鞋还是去百度,下载一个中文的文档。我的学习主要靠帮助文档。帮助文档是好东西,一来是选择这个框架,就是因为他又详细的帮助文档帮助学习很方便。
第二步:也是比较关键的一步。把该文件夹放到网站的根目录下。很多网上资料,都只说根目录下,像我这样的新手,连根目录都不知道。
下面我就跟大家讲一下根目录下。我是安装的iis,那么根目录就指的是iis的安装目录。其他的web服务器,的根目录下也就是指web服务器的安装目录。如下图:打开iis,右键,浏览,打开的就是根目录;(不会用截图软件,暂且用个大图,下次争取学会怎么截图)
第三步:关键的一步哦,注定成不成功哦。
将下载的文件拷到这个所谓的根目录下;我把这个文件夹的名字改成了php,主要是为了简便,因为还要配置访问地址。输地址方便。
第四步:最重要的,配置哦
打开application/config/config.php文件。注意.php文件可以用记事本,notpad++等多种编辑器打开,很方便,配置好保存即可。
主要配置这两个地方:标记1配置的是你要访问的网站网址。我配置的是http://localhost/php, localhost 指的是本地。也可以写成http://127.0.0.1/php。如果你有服务器,那就要写你服务器的域名咯。/php就是我刚才复制过来所下载的CodeIgniter 的文件夹,我把文件夹名字改成php就是为了访问方便,php 比CodeIgniter要简短。
标记2 index.php是下载就配置好的,没配置你就给他配置成index.php,表示你输入http://127.0.0.1/php,则自动打开index.php文件。
第五步,配置服务器,数据库,我用mysql
打开文件 application/config/database.php
配置你服务器的相关用户名,密码,数据库名等等。如下图:
这个图,不解释,大家懂得起,就是初学者,看英文都知道要填什么。
好啦,到这了,就结束了。
在浏览器中输入http://127.0.0.1/php 就可以看到index.php的欢迎界面啦。
welcome...................
原文地址:http://www.manongjc.com/article/787.html
CodeIgniter框架相关资料:

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

SecLists
SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.

WebStorm Mac version
Useful JavaScript development tools

Atom editor mac version download
The most popular open source editor

EditPlus Chinese cracked version
Small size, syntax highlighting, does not support code prompt function

DVWA
Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software