On Aug 22, 2007, at 11:12 AM, Randy Patterson wrote:
On Tuesday 21 August 2007 21:53, Anthony M Simonelli wrote:
On Mon, 2007-08-20 at 21:28 -0500, Randy Patterson wrote:
I am trying to setup a local web server on my machine to test php
projects before going live. I have installed apache2, php5 and mysql
using aptitude and apache and mysql seem to be working fine. I try to
load a test page in a browser;
http://localhost/apache2-default/test.php
The file contains a test message between header tags <h1></h1> and
below
that a php script line that just prints another test message with the
'print' command. The browser displays the first HTML message but not
the
message from the php script line. There are no errors messages. Is
there
some configuration that needs to take place after installing php5
with
aptitude?
Thanks,
Randy
First of all, disable the redirect in the default site file:
sudo vim /etc/apache2/sites-available/default
#RedirectMatch ^/$ /apache2-default/
sudo invoke-rc.d apache2 force-reload
Now, a way to test your PHP installation is to put the following in a
php file in your webserver document root (/var/www):
<?php
phpinfo();
?>
and open that file up through the browser:
http://localhost/phpinfo.php
This gives you all the information about your PHP installation.
I followed these directions, even copied and pasted the code! But all
I get is
a blank page. No error messages. See other post for another example of
the
problem.
Thanks,
Randy
You might need to add an AddHandler directive to your Apache config
file if there isn't one already and a ScriptAlias
This is what I followed when I was having troubles getting Apache to
behave and parse php right:
http://httpd.apache.org/docs/2.2/howto/cgi.html
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]