Jump to content

Debugging PrestaShop modules with Eclipse PDT and XDebug


presty

Recommended Posts

Hi,

 

I'm developing some modules with Eclipse PDT and I would like to know if anyone has an environment that allows to debug custom modules from Eclipse.

 

What I have done so far:

  1. Installed XAMPP in windows with XDebug.
  2. Installed Eclipse PDT and configured a PHP server and PHP Debuger.
  3. Configured XDebug in Eclipse to accept remote sessions (Windows>Preferences>PHP>Debug>Installed Debuggers>XDebug: Accept remote sessions = prompt)
  4. Created a PHP project containing the PrestaShop SVN project. This version has to be replicated exactly in the Server, I use FileSync extension for the sync part.
  5. Created a PHP project containing my module. This module is also Synced to the /modules folder in the server using FileSync extension.

What I have been able to do is to Debug the core of PrestaShop when I open a browser and acces the server (http://localhost/). When I do that, Eclipse prompts if I want to start a debug session and then I can go line by line debugging the code, starting at index.php.

 

The problem is that I'm not able to debug code from my custom modules. That means that when I open the browser and I go to a page which is rendered by my module, Eclipse does not stop in my breakpoints.

 

Does anyone know how to solve the problem? How are you debugging your custom modules?

 

http://andrei.gmxhom...sync/index.html

  • Like 1
Link to comment
Share on other sites

  • 1 year later...
  • 7 months later...
  • 1 month later...

If you are trying to debug class override, these overrides get copied to the folder /overrides/class/yourclass. The file that you provide in the module itself is actualy never used, so you have to set breakpoints on the copied ones.

 

Hope that helps.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...