shenkwen
shenkwen

Reputation: 3880

debugging remote website using eclipase + xdebug

I have spent several hours on the maze of eclipse's setting trying to find out how to debug a remote website but still can't get it to work. This SO is exactly what I was about to ask, after reading it, I still have something that needs to be clarified so that I can do further research.

1)It says I still need a local version of the website to be able to debug it. I don't get it: if I have to have a local version, why is it called remote debug? Is any change I make to local automatically synchronized to the remote server? Seems no because according to the question I need to manually FTP files to the server?

2)What I am trying to achieve is: with the IDE listening, when I refresh the remote webpage, the IDE takes over and displays the PHP file in its editor. Then I can debug and make changes to it, when I click save, the remote file will also be modified, is this possible at all?

Upvotes: 1

Views: 43

Answers (1)

Harikrishnan
Harikrishnan

Reputation: 9979

1) You need only the project opened in eclipse. No need to host it in your local machine. Local changes will not be automatically propagated to server until you FTP or rsync.

2) You can add break points in your IDE. Refresh webpage. When it hits break point the IDE will be automatically open(IDE should be configured to listen to remote debug connections) and stops at the line having break point.

You can use IDE plugins to automatically upload file to server and propagate the change. I'm using PHPStorm IDE for achieving the same.

Autoupload

Upvotes: 1

Related Questions