Jump to content

Recommended Posts

Hello I have tried to install PHP 5 on Apache 2.0 and 2.2.  So far when I access a test php page, I get a blank page where the source reads as the php code.  From the people I have had troubleshoot this it seems like the php is not parsing at all.

 

If anyone can help me resolve this problem it would be greatly appreciated.  I can give you any logs you may like.

Link to comment
https://forums.phpfreaks.com/topic/41796-php-is-not-parsing-correctly-or-at-all/
Share on other sites

Have you went through steps 14, 15, and 16 here?

 

P.S. Is your name a reference to the musical instrument? If so, do you play? I've considered getting one...

 

I have done those steps.  By the way I should mention I'm running on Windows XP.

 

Also yes my name does refer to the instrument.  Never played one, but I love the sound.

So I take it you've went through these?

Does your configuration check out OK when running httpd -t (I assume this is the same on Windows)?

Do you get any errors when Apache starts?

What's in Apache's error log?

 

Agreed--very cool sound. Much like that of a musical saw, which I'm trying to get better at :)

When loading PHP as an Apache Module make sure you use php5apache2_2.dll when using Apache2.2.x with PHP5. php5apache2.dll is for use with Apache2.0.x only.

 

Just adding the following few lines to the httpd.conf should be sufficient to bind PHP and Apache together:

LoadModule php5_module "C:/PHP/php5apache2_2.dll"
PHPInirDir "C:/WINDOWS"
AddType application/x-httpd-php .php

 

Note make sure you use .dll and not .so for loading PHP as a module.

 

Also make sure you save your PHP with a .php file extension and not a .txt extension. Or any other extension. It must be .php unless Apache is configured to parse other file types with PHP. - This controlled by this line in the httpd.conf:

AddType application/x-httpd-php .php

  • 5 weeks later...

I'm having the same problem and really, really need some help. $50 with Paypal for anyone that solves this for me. I tried CS at CIHost.com and no help! Site has been down for nearly 7 hours now.

 

I'm running Apache 2.0 with php 4.3.1. Don't know what happened, but all of my scripts started opening instead of parsing. I tried loading the php4 module, and the site cannot be displayed.

 

I followed the install instructions and it made the site unreadable. Any clues on this one? I'm a novice with Apache/PHP setup, so please understand.

 

Thanks,

 

Mike

I'm having the same problem and really, really need some help. $50 with Paypal for anyone that solves this for me. I tried CS at CIHost.com and no help! Site has been down for nearly 7 hours now.

 

I'm running Apache 2.0 with php 4.3.1. Don't know what happened, but all of my scripts started opening instead of parsing. I tried loading the php4 module, and the site cannot be displayed.

 

I followed the install instructions and it made the site unreadable. Any clues on this one? I'm a novice with Apache/PHP setup, so please understand.

 

Thanks,

 

Mike

 

Just found out that mysteriouslly, my httpd.conf file had a line removed:

LoadModule php4_module /usr/local/apache/libexec/libphp4.so

 

Hope this may help anyone so they don't have 24 hours of high blood pressure  ???

 

Mike

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.