Jump to content

PHP and Apache


jyc
 Share

Recommended Posts

Hello. I'm new on this forum, but I read W3Schools Tutorial since 3 years now, and I'va learned the essential in it. It's a great site.I want run some php exemples on my own computer (Windows). I've installed php, but that doesn't work ! Am I obliged install Apache too or not ?My php is only one of the W3Schools' examples :<html><body><?phpecho "Hello World";?></body></html>Does anybody help me ? Thank you.

Link to comment
Share on other sites

there is a directory named htdocs located under installation folder, there you should put the php files there and access them on a web browser at http://localhost
Thanks. So I must have all the files and directories of my website under that "htdocs". OK. I thought it was possible to have the website on a place and php on onaother. But it have in fact no importance.Thank you again.
Link to comment
Share on other sites

By the way, you don't actually need Apache to run PHP - you can run it from the command line. But to run PHP scripts as web pages you need a server, such as Apache or IIS.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...