How to make a simple php test file work under Apache?

Apache is working fine. I put in files of difft types like txt,jpg,html and they all work fine under http://localhost/filename.fileextension

However I know some files have to be moved/copied to make php work. Some changes to php.ini or httpd.conf also.    

Could you please let me know those?

I am a beginner

Thanks.
perfect_tranquilityAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

nplibCommented:
just make a php file in the document root of the web site, and call it
test.php
<?php
echo "Hello World";
?>
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
hernst42Commented:
See http://www.php.net/manual/en/install.windows.apache2.php which steps are required to make php available in apache for windows. Or use a complete apache, mysq, php stack like

http://www.wampserver.com
http://www.apachefriends.org/en/xampp-windows.html
0
perfect_tranquilityAuthor Commented:
that link,hernst ias for apache 2.0 while mine is 2.2.8 are you sure there wont be any compatibility issues????

I just was working with PHP 5.2.3 and it supposedly made the Apache server to crash. I uninstalled it and it is no longer crashing. plz provide me with a matrix that will be stable as in php5 and apache.

oracle 9i will come later. i am not using any 3rd party tools
0
Cloud Class® Course: Microsoft Azure 2017

Azure has a changed a lot since it was originally introduce by adding new services and features. Do you know everything you need to about Azure? This course will teach you about the Azure App Service, monitoring and application insights, DevOps, and Team Services.

hernst42Commented:
From the link:
Note: Apache 2.2.x Support  Users of Apache 2.2.x may use the documentation below except the appropriate DLL file is named php5apache2_2.dll and it only exists as of PHP 5.2.0.
0
perfect_tranquilityAuthor Commented:
now after doing what i thought was pertinent, i get a 500:Internal Server Error

Please ask what you think might have gone wrong,
0
hernst42Commented:
Instead of trying to set up apache and php manually use
http://www.wampserver.com
http://www.apachefriends.org/en/xampp-windows.html

http://zend.com/products/zend_core (if you ever plan to use oracle with php)

This will save you hours of putting all pieces correctly together.
0
ChorchCommented:
You should easilly see you PHP and Apache config creating a PHP file, e.g.:

http://localhost/test.php

with the following code in it:
<?php
phpinfo();
?>

Open in new window

0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
PHP

From novice to tech pro — start learning today.