Jump to content
Larry Ullman's Book Forums

Intalling With Xampp Appendix A

Recommended Posts

Hi Larry

I have been using your book for some time now (I was a poster about 3 years ago on this forum) and have to say that it still amazes me what a comprehensive and well written publication it is. I wish you would write a javascript tome in the same manner.

The question is that I have installed php and MySQL onto the D: drive of my XP Home laptop using XAMPP from www.apachefriends.org and it now appears to run well according to the XAMPP Control Panel showing Apache and MySQL "Running" but when I run a php program using Firefox it appears that php is not actually running. The browser displays the html part of the php program and looking at the Firefox source code, one can see the php code. This software works perfectly on the 1and1 server. Am I missing something?

Link to comment
Share on other sites

Hi Paul


Thanks for your input.


The website home page is www.sonningmowers.com/html which then loads the various .php pages (e.g. about us) and which works fine on 1and1 server. When I run it on the laptop and call other pages, they don't hook into php. XAMPP is running with php and mysql with svc ticked and 'Running' showing for both. phpinfo() gives me PHP version 5.3.8. I have tried your suggestion but no dice. Both the code and php are running out of the D: drive (partition). Hmmm. Baffling.

Link to comment
Share on other sites

Hi Max,


Open httpd.conf in \XAMPP\apache\conf and look at both ServerRoot (defaults to C:/xampp/apache) and DocumentRoot (defaults to C:/xampp/htdocs) and make sure they point to the correct locations. You might only have to change the drive letter. Then restart Apache and see if that fixes it.

  • Upvote 1
Link to comment
Share on other sites

Hi Paul


Tried your suggestion but locations were correct (XAMPP was in the D: drive). Uninstalled and re-installed XAMPP to the D: root but to no avail. Shows 'running' in control panel but when I call a .php file it doesn't run (except the HTML!).


Still baffled!

Link to comment
Share on other sites

Hi Larry


This is the URL of a very simple test program that I wrote to simplify matters:







$x = 5;

$y = 6;

$z = $x * $y;

echo $x . $y . $z;


In www.sonningmowers.com/phptest.php it gives the expected 5630. On the laptop I just get a blank screen (Firefox) and a source code which is the php script.



Apache, MySQL and Filezilla are all ticked and 'RUNNING' according to XAMPP Control Panel.


http://localhost/xampp/ shows:






Common Gateway Interface (CGI) ACTIVATED

Server Side Includes (SSI) ACTIVATED



Tomcat Service DEACTIVATED



HTTP Headers:...



HTTP Request GET /xampp/phpinfo.php HTTP/1.1

Host localhost

User-Agent Mozilla/5.0 (Windows NT 5.1; rv:7.0.1) Gecko/20100101 Firefox/7.0.1

Accept text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8

Accept-Language es-es,es;q=0.8,en-us;q=0.5,en;q=0.3

Accept-Encoding gzip, deflate

Accept-Charset ISO-8859-1,utf-8;q=0.7,*;q=0.7


Connection keep-alive

Referer http://localhost/xampp/navi.php



PHP Version 5.3.8


I can't help feeling that I'm missing something simple and that (as with many times in the past) I will find the answer in your book, but it escapes me at the moment.


As said before, I have had PHP MySQL running on the same laptop in the past but probably on the C: partition. Unfortunately, C: seems to be being hogged by Windows updates etc.so have to use D:


As always, help very much appreciated.

Link to comment
Share on other sites


  • Create New...