FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » PHP Runs In WinXP Command Window But Not In Browser
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: PHP Runs In WinXP Command Window But Not In Browser [message #173385 is a reply to message #173356] Thu, 07 April 2011 03:19 Go to previous messageGo to previous message
Peter Lauren is currently offline  Peter Lauren
Messages: 48
Registered: April 2011
Karma:
Member
On Apr 4, 1:19 pm, Denis McMahon <denis.m.f.mcma...@gmail.com> wrote:
> On Sun, 03 Apr 2011 04:54:02 -0700, Peter Lauren wrote:
>> I am using Windows XP have installed WAMP and PHP as outlined here
>> http://www.wampserver.com/en/........ [deleted]
>
> Simplified explanation for how php works on a webserver:
>
> 1) A surfer users their web browser to send a request to a webserver at
> "http://<host>/<path>/<file>"
>
> ("<file>" is usually somename.php)
>
> 2) The webserver at "<host>" determines what file in it's filesystem
> "<path>/<file>" refers to.
>
> 3) The webserver at "<host>" determines that the file in it's filesystem
> that "<path>/<file>" refers to should be parsed for php code before
> sending it to the surfers browser.
>
> 4) The webserver at "<host>" sends the actual file that "<path>/<file>"
> refers to to the php script processor, and then sends the output from the
> php script processor back to the web browser.
>
> You need to check that your web server is working. If it's on the same
> machine as you are developing code on, try using your web browser to
> connect to:
>
> a)http://localhost/
>
> or
>
> b)http://127.0.0.1/
>
> (If it is some other machine, modify the (a) host name or (b) ip address
> as appropriate)
>
> If your web server is working, you should get a default page announcing
> itself as apache (as you have installed wamp).
>
> If you don't get a "welcome to apache webserver" page, then you need to
> start the webserver. That is beyond the scope of my knowledge, try
> googling "wamp start webserver process"
>
> Once the web server is working, you next need to locate where the
> webserver root is. This is not the root of your hard disc (or it damn
> well shouldn't be) and will be specified in a configuration file. Again,
> google is your friend.
>
> In the document root, insert a file called phpinfo.php with the text
> between the cutlines below:
>
> ---8<--- cut here ---8<---
> <?php phpinfo(); ?>
> ---8<--- cut here ---8<---
>
> Then connect to the following url:
>
> http://<(a) server host name or (b) server ip address>/phpinfo.php
>
> And if you have been successful, and the web server is running, and your
> configuration is correct, you will get displayed on your screen a large
> amount of information about the php and web server configuration.
>
> Rgds
>
> Denis McMahon

Hi Denis,

On Win XP I went to Start:Run and ran
net start wampapache

When I go to http://localhost/, I get a page with the wampserver icon
and a bunch of stuff including the following.

Server Configuration

Apache Version :
2.2.17
PHP Version :
5.3.5
Loaded Extensions :

* Core
* bcmath
* calendar
[and several other extensions]

MySQL Version :
5.5.8
---------------------------------------------------------------

The httpd.conf file gives DocumentRoot "c:/wamp/www/"

However when I just have <a href="index.php">PHP</a>
on my web page, I get a message that it cannot find the file because
it is looking in the folder that contains the html file. When I use
<a href="c:/wamp/www/index.php">PHP</a>
I get an alert message "Firefox doesn't know how to open this address,
because the protocol (c) isn't associated with any program"

Thanks,
Peter.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: neither var_dump() nor die() displays anything
Next Topic: Spaces in filenames
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Tue Nov 26 02:54:29 GMT 2024

Total time taken to generate the page: 0.05018 seconds