-----Original Message-----
From: Janet Valade [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 04, 2004 2:44 PM
To: Balakumar Velmurugan
Subject: Re: [PHP-INSTALL] PHP5 with Apache2

Balakumar Velmurugan wrote:

> 
> -----Original Message-----
> From: Janet Valade [mailto:[EMAIL PROTECTED] 
> Sent: Thursday, November 04, 2004 12:58 PM
> To: Balakumar Velmurugan
> Subject: Re: [PHP-INSTALL] PHP5 with Apache2
> 
> Balakumar Velmurugan wrote:
> 
> 
>>Hello,
>>
>>        I configured PHP5 on my apache2 server. But every time when I try
> 
> to
> 
>>open any file with .php
>>
>>with my browser, I only see the php source. It looks like the PHP is not
>>being interpreted at the server.
>>
>> 
>>
>>I did the following as part of my setup, 
>>
>> 
>>
>>1. Built apache2 using "--enable-so" option
>>
>>2. Built PHP using "--with-apxs2=/usr/local/apache2/bin/apxs" option
>>
>>3. Modified my httpd.conf to include
>>
>>    - LoadModule php5_module libexec/libphp5.so
>>
>>    - AddType application/x-httpd-php .php .phtml
>>
>> 
>>
>>I think I am missing some configuration. Any help? Thanks in advance.
>>
>> 
>>
>>Bala
>>
>>
> 
> 
> Did you remember to restart Apache after you edited the httpd.conf file?
> 
> Do you open the files by typing localhost/filename.php into your browser 
> address line? You can't use file->open to execute php files.
> 
> Janet
> 
> 
> 
> Thanks for your response.
> 
> Yes, I did restart the server after making changes to httpd.conf. 
> 
> I have index.php at the document root. So I tried the following at the
> browser window from a different machine
> 
> http://www.servername.com/
> 
> and
> 
> http://www.servername.com/index.php
> 
> I get php source displayed as text on my window in both cases.
> 
> I also created test.php with the following content,
> 
> 
> <html>
> <body>
> <?
> echo "<br>hello world";
> ?>
> </body>
> <html>

Perhaps you don't have short tags turned on. Try:

<p?php

Janet

> 
> 
> When I point my browser at http://www.servername.com/test.php
> 
> I get a display as
> 
> hello world"; ?>
> 
> 
> Looks like the server is not invoking php !!. Any more ideas ?
> 
> Thanks
> Bala
>  


<p?php or <?php tag don't work either :(.

Reply via email to