Page 1 of 1

PHP not working although Apache is running

PostPosted: 15. November 2015 01:59
by Lucianp
I am running xampp XAMPP full Version 5.6.14 on Windows 7 x64 Ultimate.
xampp is installed in c:\xampp\
This is a new clean install. I uninstalled the previous version after I got the current problem.

I had xampp installed for a long time with it working perfectly. Today it suddenly stopped working and I got an error 500.

Looking through the error log I found this "www.example.com:443:0 server certificate does NOT include an ID which matches the server name"

I don't know why it should suddenly happen while I was working.

The only anomalies i can come up with are these:
I recently switched browsers from Firefox to Chrome several days previous and everything was still working fine. This morning I was checking out an xml file and instead of viewing with xmlNotepad it opened with Firefox. I closed off Firefox and went back to working on the project when I found I was getting the 500 error.

I've tried everything I can think of, changing ports etc. but nothing worked. I eventually uninstalled xampp, and cleaned the registry before installing a new version. Not sure of the previous version.

Even with a clean install the problem remains.

The control panel starts ok.
Apache and MySQL are running
clicking on Apache Admin brings up http://localhost/dashboard/
IIS is off
Skype is off
The only thing using port 80 is Apache

Any help will be greatly appreciated.

thanks

Re: PHP not working although Apache is running

PostPosted: 15. November 2015 02:06
by Altrea
Lucianp wrote:Looking through the error log I found this "www.example.com:443:0 server certificate does NOT include an ID which matches the server name"

Ignore this message. Are there any other messages?

Take a look into the php_error_log too

Re: PHP not working although Apache is running

PostPosted: 15. November 2015 03:57
by Lucianp
thanks for replying.
As I said, I uninstalled the original installation, cleared everything and reinstalled a newer version. The php_error_log is empty.
the new error.log is only 40 lines and repetitious of these lines

[Sat Nov 14 17:53:03.171166 2015] [mpm_winnt:notice] [pid 3264:tid 248] AH00455: Apache/2.4.17 (Win32) OpenSSL/1.0.2d PHP/5.6.14 configured -- resuming normal operations
[Sat Nov 14 17:53:03.171166 2015] [mpm_winnt:notice] [pid 3264:tid 248] AH00456: Apache Lounge VC11 Server built: Oct 13 2015 10:54:13
[Sat Nov 14 17:53:03.171166 2015] [core:notice] [pid 3264:tid 248] AH00094: Command line: 'c:\\xampp\\apache\\bin\\httpd.exe -d C:/xampp/apache'
[Sat Nov 14 17:53:03.202366 2015] [mpm_winnt:notice] [pid 3264:tid 248] AH00418: Parent: Created child process 6128
[Sat Nov 14 17:53:04.811169 2015] [ssl:warn] [pid 6128:tid 260] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Sat Nov 14 17:53:05.341570 2015] [ssl:warn] [pid 6128:tid 260] AH01909: www.example.com:443:0 server certificate does NOT include an ID which matches the server name
[Sat Nov 14 17:53:05.513170 2015] [mpm_winnt:notice] [pid 6128:tid 260] AH00354: Child: Starting 150 worker threads.


thanks

Re: PHP not working although Apache is running

PostPosted: 15. November 2015 11:52
by Altrea
This log looks good. No error messages.
Now we have a problem. You get an HTTP Status error 500 and don't find the log information for this.
Did you install Apache as Windows service? Then take a look into your Windows event log for errors.
This error must have been logged somewhere.

Re: PHP not working although Apache is running

PostPosted: 15. November 2015 21:59
by Lucianp
Thanks for the reply. How do i know if it installed as a Windows service? I just ran the installer.
I filtered event viewer to the timeframe of yesterday morning for Critical, Warning and Error and I'm not getting any of those till after the reboot.
I am able to open html pages from htdocs but not php pages
I have only been trying to open php in chrome, I now find out php files do not open in anything. The default app is sublime text 2 and I have an error on that. "Unable to read project /c/xampp/htdocs/Projects/contactform.sublime-project"

I uninstalled sublime text 2, cleaned the registry, shut down/started (not restart), downloaded a new install. Not only am I getting the same error but when I open the program, the same tabs open that were in the previous install, so it's not even uninstalling correctly.

I am not sure if this is the cause of the problem or not. I need to download a different editor, which is a shame because I really like SB2.

I'll come back and let you know if this is the cause.

thanks

Re: PHP not working although Apache is running

PostPosted: 15. November 2015 22:21
by Lucianp
Well SB2 is okay, it was referencing a backup,so that's fixed but the browser/php issue remains whether I use localhost or 127.0.0.1 nothing works

thanks for your help.

Re: PHP not working although Apache is running

PostPosted: 16. November 2015 12:19
by Nobbie
Lucianp wrote:How do i know if it installed as a Windows service?


Last not least, simply open the Windows Setup, proceed to the "Services" and watch out for MySQL and Apache Service. WIndows Services are part of Windows Operating System.

What happens, when you enter http://localhost or http://127.0.0.1 in your browser (after starting Apache)?

Lucianp wrote:but the browser/php issue remains whether I use localhost or 127.0.0.1 nothing works


Please describe more precisely what you are doing there and which messages you receive or what happens on your screen? "Nothing works" does not contain any usefull information.

Re: PHP not working although Apache is running

PostPosted: 16. November 2015 18:11
by Lucianp
Once again thanks for your help.

I have found the problem.
I am building a website using a CMS and it was those pages to which I could not get. I could get to them and suddenly I could not so I got hung up on trying to access them.
I tried a different page outside the CMS and it works.
I tried the default index page within the CMS and got the correct error message but still cannot get to my work pages which are in a theme folder so it looked like the problem was within the CMS.

I found the problem was a plugin I was using. That plugin was in use for a couple of weeks then suddenly hiccuped. ????

All is good. Thank you everyone for your help.

Re: PHP not working although Apache is running

PostPosted: 25. November 2015 22:40
by DocDee
A common problem with new/re-installs is that your php executable directory must be on your search path.
For a windows 7 install the PATH environment variable has to be set manually.
Control Panel\System and Security\System
Advanced system settings
Advanced
Environment Variables
Then restart Apache for it to take effect.
http://127.0.0.1/index.php should work.

Re: PHP not working although Apache is running

PostPosted: 25. November 2015 23:17
by Altrea
DocDee wrote:A common problem with new/re-installs is that your php executable directory must be on your search path.

Sorry but you are wrong. XAMPP is proud to run very well without any PATH variables.