Installed WAMP - how to run a PHPpage?

Installed WAMP, but not sure where to go from here.

I just want to get to the point where I can run a simple PHP page.

Thank you!

Tom
LVL 5
Tom KnowltonWeb developerAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
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.

hmarcbowerCommented:
Your base folder (where your php files will go) is probably C:\wamp\www (if you followed the default install parameters when you installed WampServer).

If that's the case, then head to that directory and create a new text file called phpinfo.php.  Inside the file, put the following:
<?php
  phpinfo();
?>

Open in new window


Load up your web browser and point it to http://localhost/phpinfo.php and it should show you your php installation details.  :)
0
Dave BaldwinFixer of ProblemsCommented:
'phpinfo' is on the main page for WAMP.  All you have to do is go to "http://localhost/" and click on it.
0
Tom KnowltonWeb developerAuthor Commented:
I can open and run the file from within PHP Designer 7.


But, when I try to run the following:

http://localhost

I get the following:

 web page not found
0
Fundamentals of JavaScript

Learn the fundamentals of the popular programming language JavaScript so that you can explore the realm of web development.

hmarcbowerCommented:
Ahh, you must be on Windows 7.

Try

http://127.0.0.1

instead.

0
Dave BaldwinFixer of ProblemsCommented:
Try the IP address of your computer.  Also, 'mywebsearch' has always been malware and a trojan downloader, I'm surprised that AVG allows it on your computer.
0
Dave BaldwinFixer of ProblemsCommented:
I wouldn't use the AVG toolbar either.  In the name of 'securing' your computer, it tries to lookup the website's reputation before it allow your browser to go there.  And, of course, it can't find 'localhost'.
0
koudryCommented:
Hello,

I have yet to use Windows 7, so my suggestion is purely around PHP.

I would like to assume you have Apache since you have a WAMP setup. Do you also have PHP path in your windows path?

Apache does not know about PHP by default, so you will need to tell Apache where PHP is and the way to do that, is to have the following files in your PHP installation direction:

php5apache2_2.dll

(e.g. C:\Program Files\PHP\php5apache2_2.dll)

You may also want to change the default Apache listening port from 80 to something like 8080.  This can be done in the httpd.conf Apache configuration file, e.g.

Listen 8080

If you have IIS installed by default on W7, then setting Apache to listen to a different port, is a good idea.

Another suggestion is that, if you have installed WAMP as a package and it is not working, it may be a good idea to uninstall it and re-install the components one at the time starting with MySQL, Apache and PHP.

Thanks.
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
Dave BaldwinFixer of ProblemsCommented:
With a WAMP (or XAMPP) installation, it is all preconfigured so Apache, PHP, MySQL, and phpMyAdmin all work together.  Installing the components individually is an ordeal at the very least because then you have to do all the configuration yourself.  I have done that and I will avoid doing that ever again if I can.
0
koudryCommented:
Hello,

The trouble is that sometimes it does not work when you have the XAMP package installed as one. You need to uninstall it and install the components individually. This gives more control.

The order in which you install the components, is very import. Quite often, this order works:

MySQL
Apache
PHP

Thanks.
0
Tom KnowltonWeb developerAuthor Commented:
thx
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.