Easy To Learning
  • Login
  • Sign Up
  • Q&A
  • Home
  • Php Tutorial
  • MySql Tutorial
  • Object-Oriented Programming
  • Java Tutorial
  • HTML Tutorial
  • React JS Tutorials
  • Free Projects
  • Blogs & Articles
  • Others
    • About Us
    • Contact Us
CakePHP Installation On Windows
Easy To Learning

Education Needs Complete Solution

Online Ask Question Question And Answer
  1. Home
  2. Cakephp Tutorials
  3. CakePHP Installation On Windows

Cakephp Tutorial

Basic CakePhp Fundamentals

  • Cakephp Table Content
  • Cakephp Introduction
  • What Is Cakephp
  • CakePHP Request Cycle
  • Cakephp Installation
  • CakePHP Installation On Windows

CakePHP Installation On Windows

How to Setup CakePHP Using Xampp On Windows

CakePHP is a web development framework that uses the MVC model. It is a free open source framework for PHP that uses the Mode-View-Controller software design pattern. Here, I will explain how you can set up CakePHP using XAMPP on a Windows 7 system. Before we proceed, it is best that you install XAMPP first, which contains PHP, Apache, and MySQL. 

Step 1: Download XAMPP and CakePHP.

Step 2: Install Xampp

Once you have installed Xampp (version 1.7.3) on your Windows with the default option, all your files will be located in the C:xampp folder.

Step 3: Mod Rewrite Module

Once Xampp is installed as the local server, you can then proceed to enable mod_rewrite. To do so, you will have to open the httpd.conf file that is located in C:xamppapacheconf and uncomment by removing # from the following line:

# LoadModule rewrite_module modules/mod_rewrite.so

Step 4: Place CakePHP Files in a New Folder

Extract the CakePHP (version 1.3.8) zip file and copy all its contents to your local web server, which in this instance is C:xampphtdocsjack. I have decided to name the CakePHP folder as Jack, and in it, you will find many files and folders for the framework, including app, cake, docs, vendors, .htaccess, and index.php.

Step 5: Set Up Virtual Host

Open the httpd-vhosts.conf file from the C:xamppapacheconfextra in order to set up new virtual host that can run your CakePHP application. You will have to add the following lines in bold font, in order to run the application:

NameVirtualHost *:80
<VirtualHost *:80>
   ServerAdmin webmaster@localhost
   DocumentRoot C:/xampp/htdocs/jack
   ServerName local.jack.com

   <Directory “C:/xampp/htdocs/jack”>
     Options Indexes FollowSymLinks Includes ExecCGI
     AllowOverride All
     Order allow,deny
     Allow from all
   </Directory>
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot C:/xampp/htdocs/xampp
ServerName localhost
<Directory “C:/xampp/htdocs/xampp”>
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>

Code Snippet 1: The httpd-vhosts.conf file will have the aforementioned configuration for virtual host to run CakePHP and other php application. I have decided to choose ‘local.jack.com’ as the server name, and likewise, we will have to add it to the C:WindowsSystem32driversetchosts file as mentioned below:

# localhost name resolution is handled within DNS itself.
127.0.0.1 localhost
127.0.0.1 local.shiya.com
# ::1 localhost

If your web server is already running, restart it so that you can access the new CakePHP installation by growing to http://local.shiya.com through your browser.

Step 6: Setting Up Database Connection

Start off setting up your database connection by renaming the database configuration file to database.php/app.php file from database.php/app.php.default file, as found in the C:xampphtdocs azibappconfig folder. Now open the database.php/app.php file and enter a username, password, and database name to the ‘$default’ connection variable:

var $default = array (
"driver" => "mysql" ,
"persistent" => false
"host" => "localhost" ,
"login" => "root",
"password" => "" ,
"database" => "shiya" ,
"prefix" => "" ,
);

Step 7: Run CakePHP

Open http://local.shiya.com on any browser and CakePHP can now access the database configuration file!

Series: Cakephp Tutorials Hub
All Topics
Free Download Projects
Previous Chapter
Next Chapter

Ask a Question

Have a coding query or doubt? Ask here and get help from our community.

500 characters remaining
Submitting...
Free Download Projects
Join Telegram Group Join WhatsApp Group
Related Topics:
how to install cakephp 3.0 in xampp cakephp installation step by step how to run cakephp project in xampp how to install cakephp 3 in ubuntu install cakephp in ubuntu install cakephp mac download cakephp cakephp composer

Member Sign In

Forgot?
Signing in...

Don't have an account? Register here

Create Free Account

Register Captcha
Registering...

Already have an account? Sign In

Ask a Question

500 characters remaining
Submitting...

About Easy To Learning

Easy To Learning is a comprehensive programming learning portal offering free, practical, developer-driven tutorials for PHP, Java, Python, Spring, MySQL, CSS, Bootstrap, CakePHP, and more.

Explore community-contributed questions and answers, and download ready-to-run source code projects.

Quick Links

  • Home
  • Questions & Answers
  • Download Projects
  • Blog & Articles
  • Member Login

Community

  • Telegram Group
  • WhatsApp Community
  • Ask a Question
  • Join as Member

Connect With Us

Stay updated with our newest programming tutorials and free open source projects.

© 2026 Easy To Learning. All Rights Reserved.