Chapter 11. Making Plug-ins

Death seed blind man's greed

Poets' starving children bleed

Nothing he's got he really needs

Twenty first century schizoid man.

King Crimson, In the Court of the Crimson King [1969]

WHAT'S IN THIS CHAPTER?

  • Making PDF plug-ins for Symfony and CakePHP

  • Introducing Zend Framework plug-in philosophy

Frameworks offer great enhancements in web development by themselves, but with plug-ins you can achieve even more! There are various ready-to-use plug-ins that greatly extend the core functionalities of the frameworks. In this chapter, we show you how to build a plug-in in all three frameworks. In Symfony and CakePHP, you will see how to create a plug-in that prepares PDF files. Plug-ins in Zend Framework are of a somewhat different nature and are dedicated to purposes different from plug-ins of other frameworks.

Plug-ins are great for two reasons. First, they help with separating code that provides certain additional functionalities from the framework's core. This way, the framework can remain lighter and achieve better performance, while the optional add-ons are installed on demand. And that's the second advantage of this approach: it is beneficial for core developers who are freed to focus on development of the framework, for the open-source community that can easily prepare and maintain plug-ins dedicated for certain solutions, for companies that may develop sophisticated commercial plug-ins, and finally for all users who can choose from the wide range of ready-to-use ...

Get Building PHP Applications with Symfony™, CakePHP, and Zend® Framework now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.