Magento PHP Developer's Guide is an easily accessible tutorial, designed and written to give the reader maximum understanding of the powerful Magento framework.This book is written for developers who have previous experience with PHP and PHP frameworks, such as Zend or CakePHP, and want to start developing and working with Magento. Even developers with previous experience with Magento will find the book extremely useful to gain a full understanding of Magento fundamentals, architecture, and overall philosophy.
Cover; Copyright; Credits; About the Author; About the Reviewers; www.PacktPub.com; Table of Contents; Preface; Chapter 1:Understanding and Setting up Our Development Environment; LAMP from scratch; Getting VirtualBox; Booting our virtual machine; Installing Apache2; Installing PHP; Installing MySQL; Putting everything together; Up and running with Vagrant; Installing Vagrant; Choosing an IDE; Working with a version control system; Summary; Chapter 2:Magento Fundamentals for Developers; Zend Framework - the base of Magento; Magento folder structure; Modular architecture; Autoloader
Code poolsRouting and request flow; Magento version of MVC; Models; Views; Dissecting a layout file; Controllers; Websites and store scopes; Factory names and functions; Events and observers; Event dispatch; Observer bindings; Summary; Chapter 3:ORM and Data Collections; Magento Model Anatomy; It's magic - methods; EAV Model; What is EAV?; Retrieving the data; Working with Magento collections; Get product collection only from a specific category; Get new products added since X date; Get Bestseller products; Filter product collection by visibility; Filter products without images
Add multiple sort ordersUsing Direct SQL; Reading; Writing; Summary; Chapter 4:Frontend Development; Extending Magento; Scenario; Features; Further improvements; Hello Magento; XML module configuration; Models and saving data; Creating the models; Setup resources; Defining a setup resource; Creating the Installer Script; What have we learned?; Setting up our routes; The index controller; The search controller; The view controller; Block and layouts; IndexController blocks and views; SearchController blocks and views; ViewController block and views; Adding products to the registry; Summary
Chapter 5:Backend DevelopmentExtending the Adminhtml; Back to the configuration; The grid widget; Managing the registries; Permissions and the ACL; Updating in bulk with Massactions; The form widget; Loading the data; Saving the data; Summary; Chapter 6:The Magento API; The Core API; XML-RPC; SOAP; RESTful API; Using the API; Setting up the API credentials for XML-RPC/SOAP; Setting up the REST API credentials; Loading and reading data; Updating data; Deleting a product; Extending the API; Extending the REST API; Securing the API; Summary; Chapter 7:Testing and Quality Assurance
Testing MagentoUnit testing; Regression testing; Functional tests; TDD; Tools and testing frameworks; Unit testing with PHPUnit; Installing Ecomdev_PHPUnit; Setting up the configuration for our extension; Anatomy of a Test case; Creating a unit test; Functional tests with Mink; Magento Mink installation and setup; Creating our first test; Summary; Chapter 8:Deployment and Distribution; The road towards zero-downtime deployment; Make it right from scratch; Be sure that what you see is what you get; Ready means ready; Version control system and deployment; SVN; Git; Distribution