The file looks like this
<?php
phpinfo();
?>
and was created in WORD saved as phpinfo.pgp
Secondly: On the same page (after creating the above and putting it
into C:/Apache/Apache2/htdocs as told) it says to point the web browser
to http://localhost/phpinfo.php and I should see the PHP information
page. All my browser does is hang up while searching for the page. What
the heck am I doing wrong ALREADY ! Geez this is HORRIBLE. Please help.
Thank you,
George
With a text editor.
>I have Word etc but programs like this create TEXT files etc. ,
>DON'T THEY?
Doesn't Windows have a text editor, like EDLIN?
>I created it anyway and did as told. Was this OK ?
>The file looks like this
><?php
>phpinfo();
>?>
>and was created in WORD saved as phpinfo.pgp
Unless WORD has a mode to save as flat ASCII text with absolutely
no fonts, color, colour, etc., it's the wrong thing to use.
How about NOTEPAD?
Gordon L. Burditt
Steve Doria
http://blog.stevedoria.net/
>This is my first day trying to learn PHP and ALREADY I'm stumped. I
>bought the SAMS Guide toPHP. MySQL, and Apache Book. On page 18 it
>tells me to create a file called phpinfo.php. HOW do I create a PGP
>file ?
PHP, not PGP. PGP is an encryption program.
>I have Word etc but programs like this create TEXT files etc. ,
>DON'T THEY? I created it anyway and did as told. Was this OK ?
PHP files are text files. The extension of a filename (the bit after the ".")
has nothing to do with the contents of the file - all it does is, on Windows
anyway, help to let the operating system know what program to open the file
with.
When you're running PHP in a webserver it has a similar function; you would
earlier have set up your webserver to run files ending with .php through the
PHP interpreter, instead of just serving the file directly as it would by
default.
>The file looks like this
><?php
>phpinfo();
>?>
>and was created in WORD saved as phpinfo.pgp
phpinfo.php.
Ensure it's not saved it as phpinfo.php.txt, as the Microsoft programs have a
bad habit of doing that.
If you're on Windows XP, make sure you have the "Hide file extensions" option
turned OFF (somewhere in Options when you have a directory window open) as this
will just confuse things further.
>Secondly: On the same page (after creating the above and putting it
>into C:/Apache/Apache2/htdocs as told) it says to point the web browser
>to http://localhost/phpinfo.php and I should see the PHP information
>page. All my browser does is hang up while searching for the page.
Is your webserver running?
Did the book start with the basics first, getting Apache to serve up a plain
page first before moving on to PHP?
--
Andy Hassall :: an...@andyh.co.uk :: http://www.andyh.co.uk
http://www.andyhsoftware.co.uk/space :: disk and FTP usage analysis tool
Sincerely,
George