This is a boilerplate template written in PHP Phalcon Framework. Its purpose is to get you up and running for your web application development. It includes:
- Authentication and ACL
- Uses security plugin for authentication and roles based ACL management
- Session
- Database Abstraction Layer
- Uses Phalcon MySQL Adaptor
- CRUD (Create, Read, Update and Delete)
- Provides sample for CRUD actions on a Model
- Pagination
- Third party libraries using Composer
- Provides example on how to integrate third party libraries (PHPExcel, PHPMailer) in your application
- Logging
- Provides application and database logging
- Grunt Integration
- Uses Grunt.js to concat and minify javascript and css files for production deployment
On my local machine I have the following versions installed.
- Apache 2.4.10
- PHP 5.5.20
- Phalcon 2.0.0
- MySQL 5.5.31
- PHP Composer
I assume you already have Phalcon framework installed. If not, then follow instructions at Phalcon Website.
Here is sample configuration to get the site running on port 9003.
Listen 9003
<VirtualHost *:9003>
ServerName localhost:9003
ServerAdmin <your-email-address>
DocumentRoot "/Library/WebServer/Documents/phalcon-boilerplate/"
DirectoryIndex "index.html" "index.php"
<Directory "/Library/WebServer/Documents/phalcon-boilerplate/">
Options +Indexes +FollowSymLinks +MultiViews +Includes
AllowOverride All
Require all granted
</Directory>
</VirtualHost>
After the above configuration, you should be able to load the page using http://localhost:9003
This example uses MySQL database. Use the included sql file to setup and initailize your database.
cd phalcon-boilerplate/app
mkdir cache cache/volt cache/security
mkdir logs
touch logs/app.log
chmod -R 777 cache logs
php composer.phar install
The following accounts are setup in database for testing.
User Type | Password | Notes | |
---|---|---|---|
Administrators | admin@test.com | admin12345 | Access to all sections of the application |
Users | user@test.com | user12345 | Access to only certain sections of the application |
I am using minimal features of a template from bootstraphunter. You are required to purchase your own template.
- Upgraded to Phalcon 2.0.0
- Added support for Composer (Dependency Manager for PHP)
- Cleaned up code to comply with PSR-1 and PSR-2
- Added support for Composer Autoloading