Phalcon is a high performance Php framework with MVC support. Its is very useful framework for developing dynamic applications rapidly. This article will help you install and enable Phalcon php framework in CentOS, Redhat and Fedora Systems.
Install Required Packages
To start with Phalcon Project, we first need to setup a running LAMP server. If you have already running LAMP stack skip this step else use followings commands to setup lamp stack.
# yum --enablerepo=remi,epel install httpd
# yum --enablerepo=remi,epel install mysql-server # service mysqld start # /usr/bin/mysql_secure_installation
# yum --enablerepo=remi,epel install php php-mysql gcc libtool # service httpd restart
Install Phalcon PHP Framework
$ cd /opt/ $ git clone https://github.com/phalcon/cphalcon.git $ cd cphalcon/build $ sudo ./install
Enable Phalcon php extension in your system.
$ echo "extension=phalcon.so" > /etc/php.d/phalcon.ini $ service httpd reload
Before proceeding for development, make sure phalcon php framework has been successfully installed with your php.
Create a info.php on your web document root with following content and access it in browser.
<?php phpinfo(); ?>
You will see output like below.
Create Project with Phalcon
As you have successfully installed phalcon php extension in your system. Lets visit below url to install Phalcon Developer Tools for creating project and add components in project.