473,739 Members | 11,054 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Apache2/PHP4 compile/startup fine but no PHP parsing (blank page for phpinfo)

Folks,

I consider myself well versed with Apache 1.3 and PHP4 - I found
drupal and wanted to try it out - I had problems getting it working
with Apache2/PHP5/MySQL5 so I downgraded... Note: I did have Apache2/
PHP5 working... I confirmed this via phpinfo output... But now that I
removed my original directory containing Apache/PHP, and recompiled
from scratch, I get everything to startup and static html is displayd,
but phpinfo produces no errors, but no output (literally zero output).

Where am i going wrong?

This is my environment (forget mysql for the moment as I just want
Apache/PHP working first)
Apache 2.0.59
PHP 4.4.5

I compile the above using the following:

# cd apache
# ./configure --prefix=/opt/apache --enable-so --enable-vhost-alias
# make
# make install
# cd ../php
# ./configure --with-apxs2=/opt/apachebin/apxs --with-mysql
# make
# make install

And i have the following in my Apache httpd.conf file

LoadModule php4_module modules/libphp4.so
AddType application/x-httpd-php .php

Note - I see in the php.chm document it asks i place the following
below the ClearModuleList
AddModule mod_php4.c

I don't have a ClearModuleList and when I put AddModule in at the end
of my httpd.conf, I get the following error:

Syntax error on line 1039 of /opt/apache/conf/httpd.conf:
Invalid command 'AddModule', perhaps mis-spelled or defined by a
module not included in the server configuration

I can't recall using AddModule before though.

If i exclude the AddModule reference, Apache starts up fine... (log
reference below)
[Sun Feb 25 14:50:51 2007] [notice] Apache/2.0.59 (Unix) PHP/4.4.5
configured -- resuming normal operations

and a httpd -l output shows this;

Compiled in modules:
core.c
mod_access.c
mod_auth.c
mod_include.c
mod_log_config. c
mod_env.c
mod_setenvif.c
prefork.c
http_core.c
mod_mime.c
mod_status.c
mod_autoindex.c
mod_asis.c
mod_info.c
mod_cgi.c
mod_vhost_alias .c
mod_negotiation .c
mod_dir.c
mod_imap.c
mod_actions.c
mod_alias.c
mod_so.c
When I connect using Firefox, I get the Apache test page. When I call
phpinfo.php, I just get a blank page and no source - I have the
Firefox Developer bar installed and get the headers listed as:

Date: Sun, 25 Feb 2007 13:55:19 GMT
Server: Apache/2.0.59 (Unix) PHP/4.4.5
X-Powered-By: PHP/4.4.5
Content-Length: 0
Keep-Alive: timeout=15, max=100
Connection: Keep-Alive
Content-Type: text/html

200 OK
Can someone tell me what i've forgotten?

Many thanks,
Randell D.

Feb 26 '07 #1
1 4808
On Feb 26, 2:18 pm, "Randell D." <fiprojects.... @gmail.comwrote :
Folks,

I consider myself well versed with Apache 1.3 and PHP4 - I found
drupal and wanted to try it out - I had problems getting it working
with Apache2/PHP5/MySQL5 so I downgraded... Note: I did have Apache2/
PHP5 working... I confirmed this via phpinfo output... But now that I
removed my original directory containing Apache/PHP, and recompiled
from scratch, I get everything to startup and static html is displayd,
but phpinfo produces no errors, but no output (literally zero output).

Where am i going wrong?

This is my environment (forget mysql for the moment as I just want
Apache/PHP working first)
Apache 2.0.59
PHP 4.4.5

I compile the above using the following:

# cd apache
# ./configure --prefix=/opt/apache --enable-so --enable-vhost-alias
# make
# make install
# cd ../php
# ./configure --with-apxs2=/opt/apachebin/apxs --with-mysql
# make
# make install

And i have the following in my Apache httpd.conf file

LoadModule php4_module modules/libphp4.so
AddType application/x-httpd-php .php
[snip]
>
Can someone tell me what i've forgotten?

Many thanks,
Randell D.
Got it!

I re-compiled everything and even did a make clean before configure
however I think I found a possible bug during re-installation...

/usr/local/lib/php existed (I guess from my previous php5
installation) and there must have been some reference to it in my /usr/
local/lib/php.ini

I removed all php references from under /usr/locallib and re-compiled
again from scratch and found that my phpinfo() worked...

I make note here in case someone else might find the same problem some
other time in the future... and need a solution...

cheers
Randell d.

Feb 26 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2246
by: Chris Haynes | last post by:
Hello all, I am attempting to install Apache 2.0.47 and php4.3.3 on slackware8.1. I am pretty new to linux and this is something of a learning experience and so I was anticipating a few problems along the way. Now I have pretty much followed the instructions at lamps.efactory.de/e-lamps-2-0.shtml word for word, but when i try to access a simple php file (<?php phpinfo(); ?>) in lynx it just shows me the source code (i.e. <?php phpinfo();...
6
2576
by: Greg Bryant | last post by:
PHP Newbie question: I installed the above, and if I point directly to a ..php file (i.e. http://localhost/phpinfo.php, I get the php script executed properly. If I put a <?php ... ?> tag in html, nothing happens. No error in any Apache logs, no obvious errors in php, nothing displayed on the page. I installed as cgi, I saw an earlier post someone recommended SAPI - could that be a problem (I'm guessing it's some line in one of the...
2
3262
by: Brad Shinoda | last post by:
I've been running apache and PHP by using apt-get packages for a long time now, and it's been working fine for me. But the other day I tried to get image functions working and hit a brick wall with the packaging. I get my packages from stable. Basically, when I tried to install php4-gd2, I get something like this: php4-gd2 depends on zendapi-20040901 I seem to have that (virtual) package already installed however. The only way I...
0
1696
by: vrillusions | last post by:
I had to compile my own php to get ldap support since the latest php packages for slackware don't have it. So I do the compile and then it doesn't work. I check the apache log and it segfaults. CLI works fine and doesn't give any errors. Here's some debug info (i know the gdb output isn't all that helpful, I guess I can enable debugging on php if it would help. although I assumed that was all coming from the apache part): Slackware...
2
14168
by: Mike | last post by:
I am sure that I am making a simple boneheaded mistake and I would appreciate your help in spotting in. I have just installed apache_2.0.53-win32-x86-no_ssl.exe php-5.0.3-Win32.zip Smarty-2.6.7.tar.gz on a system running WindowsXP SP2. Apache and PHP tested out fine. After adding Smarty, I ran the following http://localhost/testphp.php
3
1613
by: masterx | last post by:
I developed and maintained a site for someone using Apache 1.3 and PHP 4.0.3 and used to be able to reference a page without explicitly specifying the .php extension. ie. http://www.url.com/adminpage would open adminpage.php. However since I've upgraded to Apache 2.0.55 and PHP 4.4.1 this no longer works. Is this something that can be configured in my httpd.conf or has this feature been removed from Apache 2? I'm running the Windows...
2
2259
by: alkazakov | last post by:
I did the parsing XML and it works on my computer (PHP5), but as usual it doesn't on the clients server (PHP4) =) can you look into it: http://sfhousemusic.com/newlook/phpinfo.php http://sfhousemusic.com/newlook/pasingXML.php - test file with this in it: <?php error_reporting(E_ALL);
5
3370
by: NewbieSupreme | last post by:
I installed Apache 2.0.58, tested it, got the "working" page. Installed MySQL 5.0.22, and didn't really see how to test that, but there is a mysql process running in the task manager. Ran through the PHP 5.1.4 installation directions, and that seems to work, since I can use phpinfo() and get all the information on a test php page. Then I installed (really just unzipped and placed some files according to the directions) PHPMyAdmin; did...
5
2332
by: solitary.wanderer52 | last post by:
I just finished installing PHP5 on Linux (Debian/Ubuntu/Mepis)/Apache2 using Synaptic. I have tried creating simple html pages, placing them in /var/www and pointing the browser at http://127.0.0.1/(those pages) and they are displayed correctly. I have created a basic PHP page (abc.php) and it looks like: <? phpinfo(); ?>
0
8969
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8792
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9479
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9337
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9266
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8215
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6054
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4826
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3280
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.