Jump to content
The Uniform Server Community

NooB Question -- how to get PHP executing properly?


bdoors72
 Share

Recommended Posts

Please excuse this simple question but I'm having trouble getting oriented. Thanks in advance for your help.

 

I've installed Uniform Server 3.5 on Windows XP SP2. Install appears fine and Start and Stop scripts appear to work fine.

 

When I create a simple web page with embedded PHP (named mytest.html or mytest.php) and then run it by double-clicking on the file name, it does not execute the PHP code. (Also I notice that PHP is not a registered file extension under XP.)

 

What do I need to configure to get PHP executing within HTML web pages with Uniform? Thank you.

 

 

<<<<<<<<<<<<<< SOLVED >>>>>>>>>>>>>>>>>>

 

My answer was in the SERVER STRUCTURE.TXT file in the DOCS folder.

 

The HOME directory is W:\WWW. So all I had to do was place my PHP file in there like this W:\WWW.mytest.php.

 

Then execute it by opening my browser and entering the correct local host address -

 

http://localhost/mytest.php

 

Great, I'm off and running. Thanks.

Link to comment
Share on other sites

Glad you solved it yourself, but this is some information to anyone else who stumbles across this thread.

 

PHP files are not executable, meaning you can't double click them and have them run like your favourite game or any other application. They are special files that have to be interpreted which is what your webserver (such as Uniform Server) will do (provided PHP is installed on the server).

 

So all you have to do is drop the PHP file into W:/www and then browse to it using your browser: http://localhost/myfile.php

IPB Image

 

Link to comment
Share on other sites

Ric -- Thanks for the pointer into the Wiki.... lots of good info in there, I'll be spending some time reading it all.

 

I also bought the book "Teach Yourself PHP, MySQL, and Apache in 24 Hours" (is that a claim or what?) Anyway, it should help me get going quick along with the Wiki.

 

BTW, the Uniform Server has really been a *fantastic* help, allowing me to get everything installed so quickly and easily (and even though I'm using an old early P-IV as my test box, everything runs plenty fast). Thanks to Uniform, I've only spent one day on this project and already everything is installed and working, plus I'm already writing simple PHP scripts. Great productivity!

Link to comment
Share on other sites

  • 2 years later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...