Uploading a php file to wamp
Posted by: lyfe (---.cable.ubr02.live.blueyonder.co.uk)
Date: October 06, 2006 03:29PM

I've just downloaded wamp and it is currently set as online in the bottom right hand corner of my screen. "all services running - server online". With that said I have no idea how to upload a php file to the server and how to see the output. I'm just trying to learn php now for my project. Could someone please give me a step by step guide of how to do this please, i am a novice to php. Thanks

Options: ReplyQuote
Re: Uploading a php file to wamp
Posted by: andyfowles (---.server.ntli.net)
Date: October 06, 2006 10:54PM

Your php files need to be uploaded to your www directory. This can be found by clicking on the wamp tray icon and selecting 'www directory.'

This is the directory you need to move / copy / place your php files into.

The output is visible by opening a browser window and entering this URL into the address bar:

[localhost] <name of your php file>

Replace <name of your php file> with the real name i.e. index.php or phpinfo.php

This is assuming you are trying to browse from the same machine as wamp is installed on...if not replace 'localhost' with the IP address of the machine on which you installed wamp, i.e [192.168.1.2]

To see your pages in a browser from anything other than localhost you need to ensure the server is 'online'

Hope that helps.

[edit] Edited to remove typo's [/edit]



Post Edited (10-06-06 22:58)

Options: ReplyQuote
Re: Uploading a php file to wamp
Posted by: roms (---.fbx.proxad.net)
Date: October 08, 2006 09:16AM

Even easyer, just click on the wamp icon and choose "www directory"



Romain

Options: ReplyQuote
Re: Uploading a php file to wamp
Posted by: lyfe (---.cable.ubr02.live.blueyonder.co.uk)
Date: October 08, 2006 02:07PM

Thanks for the replies, okay so i've found that folder, is there anyway to easily test whether it works or not?

Options: ReplyQuote
Re: Uploading a php file to wamp
Posted by: andyfowles (---.server.ntli.net)
Date: October 08, 2006 11:23PM

The easiest way is to upload / copy a php file called phpinfo.php into it and browse to this file using your web browser. Save the text below (starting with </php) into a file called phpinfo.php and place that in your www folder then browse to:

[localhost]

using your browser.

You should see an array of details regarding the version of php that you are running.



<?php
phpinfo();
?>

Options: ReplyQuote
Re: Uploading a php file to wamp
Posted by: andyfowles (---.server.ntli.net)
Date: October 11, 2006 10:41PM

Any luck?

Options: ReplyQuote


Sorry, only registered users may post in this forum.