Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Magento 2 Development Cookbook

You're reading from   Magento 2 Development Cookbook Over 60 recipes that will tailor and customize your experience with Magento 2

Arrow left icon
Product type Paperback
Published in Dec 2015
Publisher
ISBN-13 9781785882197
Length 304 pages
Edition 1st Edition
Languages
Tools
Concepts
Arrow right icon
Toc

Table of Contents (13) Chapters Close

Preface 1. Upgrading from Magento 1 FREE CHAPTER 2. Working with Products 3. Theming 4. Creating a Module 5. Databases and Modules 6. Magento Backend 7. Event Handlers and Cronjobs 8. Creating a Shipping Module 9. Creating a Product Slider Widget 10. Performance Optimization 11. Debugging and Unit Testing Index

Getting started with Xdebug


With a real debugger, you can pause the execution of the script. It allows you to have a look at the variables and values that they have at that point. In a debugger, you can also change values, skip statements, and a do much more.

In PHP, there is the Xdebug extension that enables you to use a debugger in combination with an IDE. In this recipe, we will see how to install Xdebug and integrate it with the IDE NetBeans.

Getting ready

In this recipe, we will start an Xdebug session with the NetBeans IDE. Open NetBeans and set the Magento Project as Main Project. Ensure that all the URLs are configured correctly in the Property settings of the project.

To install Xdebug, you have to ensure that the php5-dev and php-pear packages are installed on your server. If not, you can install them using the following commands:

sudo apt-get install php5-dev
sudo apt-get install php-pear

How to do it...

The following steps describe how you can install Xdebug on your development server...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at ₹800/month. Cancel anytime