0

I am running on Windows 10 with NetBeans 8.2 and XDEBUG 2.5.

When I click Debug/File Chrome opens with

http://localhost/d8mod/modules/custom_modules/emailreminder/emailreminder.module?XDEBUG_SESSION_START=netbeans-xdebug with "Site can't be reached".

php.ini contains xdebug.remote_host=localhost:8080

the :8080 part is ignored. It does not matter whether it's in quotes on not.

What am I doing wrong?

Panda
  • 6,955
  • 6
  • 40
  • 55
Sam Stamport
  • 157
  • 1
  • 10
  • `xdebug.remote_host` should be an IP or domain name only. In your case -- `localhost`. Based on your whole message -- you have little understanding how xdebug works and what that option do. Please read xdebug documentation first. – LazyOne Jan 01 '17 at 15:11
  • 1
    I am a newbie to Drupal and this whole business of xdebug. I HAVE read lots of documentation. Please do not assume that everyone on this forum has all the experience that you have. If you don't have something constructive to say, please don't say anything. – Sam Stamport Jan 01 '17 at 15:59

1 Answers1

1

I think, you'll have to update your project settings in Netbeans, because it calls the wrong URL.

The URL Netbeans calls after pushing the debug button is configured in project settings / "Run Configuration".

The field "Run As" should be "Local Web Site (Running on local web server)" as you're using localhost and the Project URL should be http://localhost:8080/[Project PATH], where [Project PATH] is the path to your project.

I hope, this helps.

akrys
  • 563
  • 1
  • 3
  • 9
  • Thanks for your helpful answer. The URL is now correct, but I'm getting "Error 403 localhost Apache/2.4.23 (Win32) OpenSSL/1.0.2h PHP/7.0.13. Can you help me fix this problem? I'm a newbie and need all the help I can get. – Sam Stamport Jan 01 '17 at 15:58
  • That sounds as if apache could not access the directory. Usually this is a file rights issue. Does it only happen, if you want to debug? – akrys Jan 01 '17 at 16:01
  • Yes. Only happens when attempting to debug. What windows folder should I look at for file rights? Your help is greatly appreciated! – Sam Stamport Jan 01 '17 at 16:12
  • If it's accessible on a normal bases, it can be a problem with XDEBUG config. Does the apache error log gives a hint? – akrys Jan 01 '17 at 16:28
  • I get four identical messages in the log "[Sun Jan 01 10:34:35.162429 2017] [authz_core:error] [pid 8768:tid 1824] [client ::1:56826] AH01630: client denied by server configuration: C:/xampp/htdocs/d8mod/modules/custom_modules/emailreminder/emailreminder.module". I changed permissions on the emailreminder folder & the module file to allow anything. ("emailreminder" is the name of the module I'm trying to write.) – Sam Stamport Jan 01 '17 at 16:40
  • From a short research, I found http://stackoverflow.com/questions/18392741/apache2-ah01630-client-denied-by-server-configuration. So I think there is a configuration problem. – akrys Jan 01 '17 at 16:51
  • Another Problem could be the IP: The Client is using IPv6 `[client ::1:56826]` Perhaps your Apache is only configured for IPv4, and sends the response only to `127.0.0.1`. But that's only a guess – akrys Jan 01 '17 at 16:51
  • When I check all the stuff for PHP from within Drupal I see that IPV6 is enabled. I followed instructions in the link for the configuration problem, but it does not seem to solve the problem. httpd.conf is set like this:Directory /> AllowOverride none Require all denied DocumentRoot "C:/xampp/htdocs" AllowOverride All Require all granted AllowOverride All Options None Require all granted AllowOverride none Require all denied – Sam Stamport Jan 02 '17 at 00:08
  • hm, apache config is always trial and error. From what I can see, it looks OK. Sorry that I can't help at this point. – akrys Jan 02 '17 at 07:44