5

I have been mucking around for days, trying to find the right combination that lets me debug with breakpoints and variable viewing, in Eclipse, without crashing Apache.

  • PHP 5.3? PHP 5.2?
  • Eclipse Helios? Eclipse Galileo? One or the other with certain versions of xdebug or php? Or do I need to use NetBeans or something else?
  • Is my 64 bit OS the problem? Do need specific 64bit versions of PHP, Eclipse or Xdebug to work on Windows 7 64?
  • Any special xdebug config options and tricks that I need in php.ini? Like turning off xdebug.profiler_enable or not using quotes around my zend_extension path to the xdebug dll?
  • A Vhosts issue?
  • Scrap the whole thing and go back to Win XP or Ubuntu?

Here's what I've already been reading:

Basically what would be great is if folks could post their working (i.e. debugging with breakpoints and local variable viewing in Eclipse) Win7 64bit configurations, including:

  • PHP version (5.3.1, 5.2.11, etc)
  • Xdebug dll (2.1.0-5.3-vc6, etc)
  • Xdebug php.ini config (zend_extension = "C:\xampp\php\ext\php_xdebug.dll", etc)
  • Apache version (2.2.14, etc)
  • Anything else important? The "secret ingredient"?

Thanks! I miss my debugger since I got a new laptop with Win 7 :(

Note: Moved to SuperUser
https://superuser.com/questions/231818/what-php-xdebug-and-eclipse-configurations-work-on-windows-7-64-bit

Community
  • 1
  • 1
thaddeusmt
  • 15,410
  • 9
  • 67
  • 67
  • I suppose you are right, it does belong on SuperUser, I just live on StackOverflow so this is my instinct (and there other good Eclipse/Xdebug questions over here on SO). I wouldn't say Windows *isn't* the "native" platform of Eclipse though, if you are familiar with the premise of the JVM. And isn't the point of any question to reduce the amount of trail and error needed to solve a problem? But I will close and move. – thaddeusmt Jan 11 '11 at 15:29
  • Hmm, did not know you cannot close or delete a question with a bounty on it. That should be in the FAQ. – thaddeusmt Jan 11 '11 at 15:58

4 Answers4

2

So, here is what I am using now on my Windows 7 64 laptop, which seems to be working:

  1. Eclipse Helios Service Release 2 (3.6.2)
  2. Apache 2.2.17
  3. PHP 5.3.4
  4. XDebug 2.1.0-5.3 (VC9 I think)

I used the WAMP Server 2.1d 64bit installer. WAMP is waaaay better than XAMPP, like, I can't even believe. My life is good again.

I ran in to a couple of problems still, namely the OpenSSL files included with Apache didn't work. But I just downloaded the latest files from the OpenSLL and overwrote the files WAMP came with, and now it works great.

I also had to enable some of the bonus features on PHPMyAdmin I like, and had to add the INI parameter to the mySql service to use the MySql Administrtaor program, but overall it worked slick. Very stable now.

Anyway, I can set breakpoints and inspect local variables now! And still use my favorite Eclipse IDE! Thanks for everyone's suggestions, please feel free to continue to post working configurations to help everyone else out.

thaddeusmt
  • 15,410
  • 9
  • 67
  • 67
0

I had the same problem.
I had wamp 2.2 installed with the following:
the 64 bit thread safe version of Apache built with vc-9 \
Apache 2.4.2
Php 5.4.3
MySQL 5.5.24
php_xdebug-2.2.0-5.4-vc9-x86_64.dll - this version of XDebug did not work, but after
downloading and installing:
php_xdebug-2.2.3-5.4-vc9-x86_64.dll - the most recent threadsafe version, my eclipse debugger is working properly.

Kevin
  • 1
0

Windows 7 64bit. I use X-debug 2.1.0 on Netbeans 6.9.1 and 7.0 beta, PHP 5.2.6, Apache 2.2.3 if I recall, but it shouldn't matter.

php.ini:

zend_extension_ts="C:\work\xampp\php\ext\php_xdebug-2.1.0-5.2-vc6.dll"
xdebug.remote_enable=On
xdebug.remote_host=127.0.0.1
xdebug.remote_port=9000
xdebug.remote_handler=dbgp

In Netbeans menu Tools --> Options --> PHP --> General: make sure the PHP interpreter file points correctly, and the Xdebug port is 9000.

Finally, for web site debugging I use Easy XDebug for Firefox, which adds the Xdebug session parameter in the requests.

Fanis Hatzidakis
  • 5,282
  • 1
  • 33
  • 36
  • Thanks, I do intend to try reverting to PHP 5.2 (better for Drupal work anyway). I'm used to Eclipse though, and hesitate to switch to NetBeans, but perhaps I will. I'll accept the answer that works best, after I try a few. – thaddeusmt Jan 07 '11 at 22:20
  • @thaddeusmt to add to this, xdebug has a page where you can paste your php.ini to get a suggestion on which xdebug.dll to download based on architecture/version: http://xdebug.org/find-binary.php . Also, netbeans has an "Eclipse" keyboard shortcuts profile to ease transitions. – Fanis Hatzidakis Jan 12 '11 at 07:14
0

I am currently using Windows 7 64bit and I am currently using the EasyPHP Stack to develop my PHP project. As far as I am aware you can easily use 32bit without any problems at all. The EasyPHP stack includes XDebug so it should be relatively simple for you to set up.

Netbeans can be downloaded in either 32bit or 64bit however there are meant to be problems with using the 64bit version and I have been using the 32bit Netbeans without any problems.

Hope this will be helpful!

Daniel West
  • 1,808
  • 2
  • 24
  • 34