Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Getting Started with Magento Extension Development
  • Table Of Contents Toc
  • Feedback & Rating feedback
Getting Started with Magento Extension Development

Getting Started with Magento Extension Development

By : Branko Ajzele
5 (2)
close
close
Getting Started with Magento Extension Development

Getting Started with Magento Extension Development

5 (2)
By: Branko Ajzele

Overview of this book

Modules, are a group of php and xml files meant to extend the system with new functionality, or override core system behavior. Most of the base Magento system is built using the module system, so you can see why they are an important feature for this rich open-source e-commerce solutions. This book explores key module development techniques and teaches you to modify, understand and structure your modules making it easy for you to get a strong foundation for clean and unobtrusive Magento module development. Getting Started with Magento Extension Development is a practical, hands-on guide to building Magento modules from scratch. This book provides an in depth introduction and helps you discover features such as; blocks, controllers, models, configuration files, and other crucial elements which contribute to the Magento architecture. This book introduces the you to real-world modules and helps provide a strong foundation which you need to become a professional Magento module developer. The book further explores best practices and tips and tricks offering you the ultimate go to guide. Getting Started with Magento Extension Development focuses on three areas. First you are guided through the entire Magento structure, where each important directory or file is explored in detail. Then the essence of the module structure and development is explained through the detailed coverage of models, blocks, controllers, configuration, and other files that manifest a single module. Finally, a detailed set of instructions is given for building four real-world modules, including a payment and shipping module.
Table of Contents (13 chapters)
close
close
Getting Started with Magento Extension Development
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
1
Index

Extension business logic


In our extension, entire business logic is contained within a single app/code/community/Foggyline/Stripe/Model/Payment.php file. We are including the external Stripe library via the require_once dirname(__FILE__).'/../lib/Stripe.php'; statement. Then we are implementing the Stripe_Charge::create API call within the capture method, passing it the customer and credit card information. Since we are using the Stripe PHP library, there is not much of the code we need to write ourselves, so the implementation is pretty short and clean.

If you successfully executed all the previous steps, you should now have a functional payment extension. Although simple, functionality of this extension can be further extended by adding the rest of the methods such as authorize, refund, and cancel. Authorize action is actually already contained within the capture method, but sometimes you might want to first authorize the payment then later manually capture it.

Visually different images
CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Getting Started with Magento Extension Development
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon