Friday, September 10th, 2010

Installing CakePHP on Localhost Environment

CakePHP is a rapid development framework for PHP that provides an extensible architecture for developing, maintaining, and deploying applications. Using commonly known design patterns like MVC and ORM within the convention over configuration paradigm, CakePHP reduces development costs and helps developers write less code.

The following are the prerequisites for the environment for installing cakephp.

  • Apache server with mod_rewrite
  • PHP 4.3.2 or greater
  • MySQL (Cake does support PostgreSQL, Microsoft SQL Server 2000, Firebird, IBM DB2,Oracle, SQLite, ODBC, and ADOdb)

Downloading CakePHP:

Download the latest stable release of Cake version 1.2.6 from www.cakephp.org.
After downloaing the compressed file, extract the Cake release file, you should end up with a folder named like cakephp-cakephp1x-xxxxxx with sub folders inside it. The current downloads are offered from github. The following is the standard folder structure in CakePHP

app            <DIR>
cake           <DIR>
vendors        <DIR>
.gitignore     1 KB
.htaccess      1 KB
index.php      3 KB
README         2 KB

The app folder is the core of a newly developed application and the cake folder contains the guts of CakePHP. It contains all the libraries and scripts.The docs folder holds change log information and other readme files. Any other non-Cake PHP scripts needed in your application are stored in the vendors folders.

Folder structure in app directory:

config                   	<DIR>
controllers              	<DIR>
locale                   	<DIR>
models                   	<DIR>
plugins                  	<DIR>
tests                    	<DIR>
tmp                      	<DIR>
vendors                  	<DIR>
views                    	<DIR>
webroot                  	<DIR>
.htaccess                	1 KB
index.php                	1 KB

All the extracted files must be in the root of the webserver, generally in folders named webroot, www, or public_html

When you navigate to http://localhost, you must get the following screen if cake php is successfully setup.

Share Article/Example:
  • DotNetKicks
  • DZone
  • StumbleUpon
  • Print
  • Add to favorites
  • Digg
  • del.icio.us
  • Twitter
  • Facebook
  • LinkedIn
  • Posterous
  • Slashdot

Readers Comments (0)




Please note: Comment moderation is enabled and may delay your comment. There is no need to resubmit your comment.


Latest Additions

Popular User Submitted Links

1


Hosted & Optimized JS Libraries – Cached Commons

1


Multi-File Uploader & Resizer – Agile Uploader

1


Open source online notebook-to-do-list manager

1


3 tier app design in silverlight using azure & RIA services

1


Polymaps – A JS Library For Image & Vector-Tiled Maps

eXTReMe Tracker