ZandarGlass Posted October 22, 2013 Share Posted October 22, 2013 My apologies if this is in the wrong section - I didn't see anything dedicated to xampp, or my noob question anyway. I've installed XAMPP in c:/xampp, and wrote a very simple php file that just displays a line of text. I can't seem to get this file to display in /localhost/ environment. When I run it on my remote host, it runs fine, but I want to use my localhost location, of course. These are the folder structures: C:/xammp/htdocs/webd/error.php I'm loading the file in IE10 using: http://localhost/webd/error.php I get the following: Server error! The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there was an error in a CGI script. If you think this is a server error, please contact the webmaster. Error 500 localhostApache/2.4.4 (Win32) OpenSSL/0.9.8y PHP/5.4.19 I verified my Apache module is turned on and running in the XAMPP control panel (v3.2.1). I can't get any php page to run on my localhost so whatever I'm doing it's global, I figure I installed xammp incorrectly or I'm not loading the file right. I tried using variations like http://localhost/htdocs/webd/error.php, and even tried changing the filename to an html extension and tested it by opening it using C:/xampp/htdocs/webd/error.html and the file displays, so it's there, and I don't have some weird folder issue (as far as I can tell). I'm pretty sure this is a basic issue, something that I'm doing or did that was dumb or I'm just being dense for some reason. Any help out there? Quote Link to comment Share on other sites More sharing options...
ZandarGlass Posted October 22, 2013 Author Share Posted October 22, 2013 Through more testing I have found that if I place a file (helloworld.php, etc.) in the root it works. But any folder under the root fails. This works:http://localhost/hello.php This does not work: http://localhost/webd/hello.php Sorry for being so confusing. Quote Link to comment Share on other sites More sharing options...
Ch0cu3r Posted October 22, 2013 Share Posted October 22, 2013 This Server error! The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there was an error in a CGI script. If you think this is a server error, please contact the webmaster. Error 500 localhostApache/2.4.4 (Win32) OpenSSL/0.9.8y PHP/5.4.19 Means the http server encountered an error trying to run error.php Check Apaches error logs for why you are getting that error (I think the error log is located in C:\XAMPP\Apache\logs\error.log). Look at the last line for most recent error messages. What is the error? Quote Link to comment Share on other sites More sharing options...
ZandarGlass Posted October 22, 2013 Author Share Posted October 22, 2013 Thanks! I found the issue. When I made the last backup from my remote server I inadvertently included the .htaccess file. I removed that from my local folder and now it works fine. Now, on to the next problem ... for tomorrow!! Thanks a ton! I reviewed the error.log and it mentioned the .htacess file, which didn't make any sense to me to be in my local copy I've been using for learning. I opened the .htaccess file and took a look and recalled the garbage I'd stuck in there, removed it, and everything is ok. Thanks! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.