Book Image

Learning FuelPHP for Effective PHP Development

By : Ross Tweedie
Book Image

Learning FuelPHP for Effective PHP Development

By: Ross Tweedie

Overview of this book

<p>PHP frameworks have been around for a number of years. FuelPHP was one of the first frameworks built for PHP 5.3. It makes use of more advanced features of the language to allow you to focus on delivering features and code for your projects. FuelPHP allows you to quickly build prototypes using scaffolding and command-line tools, thus allowing you to concentrate on the fun part of trialling ideas and concepts.</p> <p>This practical guide will show you how to use FuelPHP to quickly create projects more quickly and effectively. You will learn everything you need to know when creating projects with FuelPHP, including how to adapt the project as ideas change and develop.</p> <p>This guide is packed with several tutorials that will help you to build a powerful and engaging application, and in the process you will learn more about FuelPHP. This book explores how to install and build a FuelPHP project in a step- by- step approach.</p> <p>Starting with an exploration of the features of FuelPHP, this book then delves into the creation of a simple application. You will then move on to scaffolding your application using the powerful FuelPHP Oil command-line tool. Next, you will be introduced to packages and modules, and also cover routing, which allows for cleaner URL structures.</p> <p>The book concludes with an introduction to the PHP community.</p>
Table of Contents (14 chapters)

Preparing the development environment


FuelPHP should work with any web server, and has been tested to work on Apache, IIS, and Nginx. It has also been built to work on Windows and *nix (Unix, Linux, and Mac) operating systems.

As far as this guide goes, the examples will be based on *nix and Mac, but the same steps will work on other operating systems such as Windows.

Apache

Other web servers are available, but for the purpose of this book we assume the use of Apache.

For the use of clean URLs such as http://example.com/welcome/hello, Apache will need the mod_rewrite module installed and enabled.

PHP

You're likely to already have PHP installed, especially with an interest in FuelPHP.

FuelPHP requires PHP Version 5.3 or greater. It also uses several PHP extensions:

  • fileinfo(): This extension is used for uploading files and may require a manual installation on Windows

  • mbstring(): This is used throughout the framework

  • mcrypt: This is used for the core crypt functions

  • PHPSecLib: This is used as an alternative...