Wiley 978-0-470-88734-9 Datasheet

Browse online or download Datasheet for Software manuals Wiley 978-0-470-88734-9. Wiley Building PHP Applications with Symfony, CakePHP, and Zend Framework User Manual

  • Download
  • Add to my manuals
  • Print
  • Page
    / 28
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 0
1
Introducing Symfony, CakePHP,
and Zend Framework
An invasion of armies can be resisted, but not an idea whose time has come.
— Victor Hugo
WHAT’S IN THIS CHAPTER?
General discussion on frameworks.
Introducing popular PHP frameworks.
Design patterns.
Everyone knows that all web applications have some things in common. They have users
who can register, log in, and interact. Interaction is carried out mostly through validated and
secured forms, and results are stored in various databases. The databases are then searched,
data is processed, and data is presented back to the user, often according to his locale. If only
you could extract these patterns as some kind of abstractions and transport them into further
applications, the development process would be much faster.
This task obviously can be done. Moreover, it can be done in many different ways and in
almost any programming language. That’s why there are so many brilliant solutions that
make web development faster and easier. In this book, we present three of them: Symfony,
CakePHP, and Zend Framework. They do not only push the development process to the
extremes in terms of rapidity but also provide massive amounts of advanced features that have
become a must in the world of Web 2.0 applications.
c01.indd 1c01.indd 1 1/24/2011 5:45:10 PM1/24/2011 5:45:10 PM
COPYRIGHTED MATERIAL
Page view 0
1 2 3 4 5 6 ... 27 28

Summary of Contents

Page 1 - COPYRIGHTED MATERIAL

1Introducing Symfony, CakePHP, and Zend FrameworkAn invasion of armies can be resisted, but not an idea whose time has come. — Victor HugoWHAT’S IN T

Page 2 - Framework versus Library

10 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORKdisproportionally huge and perhaps somewhat excessive. Here is an overview of a few

Page 3 - Advantages

OPEN SOURCE PHP WEB FRAMEWORKS x 11Agavi Started: 2005License: LGPLPHP versions: 5.2.0+ (recommended 5.2.8+)Its logo is shown in Figure 1-8. Website:

Page 4 - Disadvantages

12 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORKYii Started: 2008License: BSDPHP versions: 5.1.0+Its logo is shown in Figure 1-11.

Page 5

OPEN SOURCE PHP WEB FRAMEWORKS x 13QcodoStarted: 2005License: MITPHP versions: 5.xIts logo is shown in Figure 1-14. Website: www.qcodo.comQcodo is an

Page 6

14 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORKDESIGN PATTERNS IN WEB FRAMEWORKSThere are certain abstractions that can be transpo

Page 7 - The First Look

DESIGN PATTERNS IN WEB FRAMEWORKS x 15 ‰Model — Represents the business logic of the application. It is more than just the raw data; the Model has to

Page 8 - CakePHP logo

16 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORKconferred by the authors of the frameworks. So we will call all frameworks Model-Vi

Page 9 - Other Frameworks

DESIGN PATTERNS IN WEB FRAMEWORKS x 17 private static $isRented = FALSE; private function __construct() { } static function rentCar() {

Page 10 - Lithium

18 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORK } else { $this->drivesCar = TRUE; } } function r

Page 11 - FIGURE 110: Prado logo

DESIGN PATTERNS IN WEB FRAMEWORKS x 19Customer_2 wants to rent the car. Again.Customer_2 says: I drive Dodge Magnum really fast! The Singleton patter

Page 12 - FIGURE 113: Seagull logo

2 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORKWHAT ARE WEB APPLICATION FRAMEWORKS AND HOW ARE THEY USED?A web application framewor

Page 13 - PHP On Trax

20 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORK<?phpabstract class CarPrototype { protected $model; protected $color;

Page 14 - What Is a Design Pattern?

DESIGN PATTERNS IN WEB FRAMEWORKS x 21echo ‘Fine, we will paint your ‘.$customersCar->getModel(). ‘ ‘.$customersCar->getColor().’.<br /

Page 15 - MVC versus MVP

22 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORKdecorated object and extends its responsibilities dynamically. It is like putting a

Page 16 - Singleton

DESIGN PATTERNS IN WEB FRAMEWORKS x 23<?php class CarDecorator { protected $car; protected $gearMessage; protected $comfortMessa

Page 17

24 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORK echo ‘Driving the car without decoration: <br />’; echo $car->drive() .

Page 18

DESIGN PATTERNS IN WEB FRAMEWORKS x 25So, how do you create such Chain of Responsibility? The main idea of this pattern is to process a request by a

Page 19 - Prototype

26 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORKapplication may display different pages depending on which steps are needed to comp

Page 20

DESIGN PATTERNS IN WEB FRAMEWORKS x 27of traversal can be produced for both of them. When Client calls the next() method, different ordering algorith

Page 21 - Decorator

c01.indd 28c01.indd 28 1/24/2011 5:45:22 PM1/24/2011 5:45:22 PM

Page 22

WHAT ARE WEB APPLICATION FRAMEWORKS AND HOW ARE THEY USED? x 3is nothing wrong with a piece of code being a library, as it is just a different entity

Page 23

4 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORK ‰For producing consecutive apps, in which modularity and reusability of pieces of c

Page 24 - Chain of Responsibility

WHAT ARE WEB APPLICATION FRAMEWORKS AND HOW ARE THEY USED? x 5technologies. Then in 2005 there was a boom of Ruby. Everyone was amazed with the elega

Page 25

6 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORKOPEN SOURCE PHP WEB FRAMEWORKSAnother question we want to answer is why we have chos

Page 26 - Iterator

OPEN SOURCE PHP WEB FRAMEWORKS x 7FIGURE 12: Comparison of search volumes of di erent PHP frameworksThe First LookThe fi rst look at the frameworks

Page 27 - Iterator pattern structure

8 x CHAPTER 1 INTRODUCING SYMFONY, CAKEPHP, AND ZEND FRAMEWORKtested agile codebase. Zend Framework is focused on building more secure, reliable,

Page 28

OPEN SOURCE PHP WEB FRAMEWORKS x 9CakePHP was started in 2005 by the effort of Polish web developer Michał Tatarynowicz. Heavily inspired by Ruby on

Comments to this Manuals

No comments