The developers of Phalcon made it their mission to develop the fastest and most efficient PHP framework around, and they have done a good job of completing that mission. With the speed of C programming, simplicity of PHP, and the structure of a framework, Phalcon streamlines web application development.
Getting Started with Phalcon is an introduction to using Phalcon to develop web applications. You will learn by building a blog application using Phalcon Developer Tools and web tools to flesh out the CRUD skeleton for the application quickly, and then modifying it to add features.
As features are added to the blog, you will learn how to use other Phalcon functionalities such as the Volt template engine, view helpers, PHQL, validation, encryption, cookies, sessions, and event management.
Chapter 1, Installing Phalcon, covers installing the Phalcon PHP extension on Linux, Windows, or Mac, and configuring PHP, Apache, or Nginx.
Chapter 2, Setting Up a Phalcon Project, covers setting up a project in Phalcon manually using Phalcon Developer Tools or Phalcon web tools.
Chapter 3, Using Phalcon Models, Views, and Controllers, covers the MVC structure of Phalcon.
Chapter 4, Handling Data in Phalcon, covers Phalcon Models in depth, PHQL, session data, and filtering and sanitizing data.
Chapter 5, Using Phalcon's Features, covers even more features in Phalcon, including hashing passwords, controlling user access, setting cookies, and using view partials, logging, and view helpers.
This book is intended for PHP developers who want to learn how to use the Phalcon PHP framework. Some knowledge of PHP but no prior knowledge of MVC frameworks is required.
In this book, you will find a number of styles of text that distinguish between different kinds of information. Here are some examples of these styles, and an explanation of their meaning.
Code words in text, database table names, folder names, filenames, file extensions, path names, dummy URLs, user input, and Twitter handles are shown as follows: "So, we have to locate the php.ini
file and edit it."
A block of code is set as follows:
phalconBlog/ app/ config/ controllers/ library/ logs/ models/ plugins/ views/ index/ layouts/ public/ css/ files/ img/ js/ temp/
Any command-line input or output is written as follows:
sudo apt-get install git sudo apt-get php5-devphp-mysqlgcc
New terms and important words are shown in bold. Words that you see on the screen, in menus or dialog boxes for example, appear in the text like this: "So, search for the word Compiler in your browser window."
Feedback from our readers is always welcome. Let us know what you think about this book—what you liked or may have disliked. Reader feedback is important for us to develop titles that you really get the most out of.
To send us general feedback, simply send an e-mail to <[email protected]>
, and mention the book title through the subject of your message.
If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide on www.packtpub.com/authors.
Now that you are the proud owner of a Packt book, we have a number of things to help you to get the most from your purchase.
You can download the example code files for all Packt books you have purchased from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you. You can also find all the code used in the book by visting GitHub page http://eristoddle.github.io/phalconBlog/.
Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you find a mistake in one of our books—maybe a mistake in the text or the code—we would be grateful if you would report this to us. By doing so, you can save other readers from frustration and help us improve subsequent versions of this book. If you find any errata, please report them by visiting http://www.packtpub.com/support, selecting your book, clicking on the errata submission form link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata will be uploaded to our website, or added to any list of existing errata, under the Errata section of that title.
Piracy of copyright material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works, in any form, on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.
Please contact us at <[email protected]>
with a link to the suspected pirated material.
We appreciate your help in protecting our authors, and our ability to bring you valuable content.
You can contact us at <[email protected]>
if you are having a problem with any aspect of the book, and we will do our best to address it.