473,414 Members | 1,888 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,414 software developers and data experts.

Installing PHP - "test.php" not Working?

I'm a newbie to Apache. This week I installed my first Apache 2.0 server,
and it's working fine. I then installed PHP. When I ran the PHP test file
("test.php"), the actual text contents of the file came up in the
browser:

----------------
<?php
phpinfo();
?>
----------------

I confirmed that my Apache installation includes the "mod_so.c" module. I
made sure that the file "test.php" was in the default htdocs folder. I
confirmed that my "httpd.conf" file contained the lines :

----------------
LoadModule php4_module /Library/Apache2/modules/libphp4.so
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
----------------

I made sure that the directory /Library/PHP4 was installed, and that the
"libphp4.so" file was located in /Library/Apache2/modules.

I logged out of my system (Mac OS-X 10.3.2) and logged back in, to make
sure that Apache restarted.

What am I missing? How can I get PHP working? Thanks in advance to all
for any info.

-Vik
Jul 17 '05 #1
3 5484
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Vik Rubenfeld wrote:
I logged out of my system (Mac OS-X 10.3.2) and logged back in, to make
sure that Apache restarted.


Now I known nothing about OSX, but I'm told it's not unlike
a unix underneath all the eye-candy. If that is the case, I
would think you need to do more then a logout to have Apache
restarted. Did you try a reboot?
Bob

- --
| B. Johannessen <bo*@db.org> +47 97 15 20 09 - http://db.org/
| Mail & Spam - News, Drafts & Standards - http://db.org/blog/
| On The Origin Of Spam; Spam Statistics - http://db.org/spam/
- --
-----BEGIN PGP SIGNATURE-----

iD8DBQFAOBKfooisUyMOFlgRAjN9AJ98mgNHYmmq/UdQtLYQjNAxtYORjgCggLiN
DG2ezDdRa6VMML0PpLGB218=
=FS6F
-----END PGP SIGNATURE-----
Jul 17 '05 #2
"B. Johannessen" <bo*@db.org> wrote:
Did you try a reboot?


I just read your post and tried a reboot, but it hasn't gotten PHP
working yet.

-Vik
Jul 17 '05 #3

"Vik Rubenfeld" <vi**@mindspring.com.invalid> wrote in message
news:vi************************@news2.west.earthli nk.net...
I'm a newbie to Apache. This week I installed my first Apache 2.0 server,
and it's working fine. I then installed PHP. When I ran the PHP test file
("test.php"), the actual text contents of the file came up in the
browser:

----------------
<?php
phpinfo();
?>
----------------

I confirmed that my Apache installation includes the "mod_so.c" module. I
made sure that the file "test.php" was in the default htdocs folder. I
confirmed that my "httpd.conf" file contained the lines :

----------------
LoadModule php4_module /Library/Apache2/modules/libphp4.so
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
----------------

I made sure that the directory /Library/PHP4 was installed, and that the
"libphp4.so" file was located in /Library/Apache2/modules.

I logged out of my system (Mac OS-X 10.3.2) and logged back in, to make
sure that Apache restarted.

What am I missing? How can I get PHP working? Thanks in advance to all
for any info.

-Vik


Try to type this as address in your browser:
http://127.0.0.1/test.php
or
http://localhost/test.php

This should work if your test.php is in apache htdocs folder. I had similar
problem when I was first time installing PHP, and this was the solution.
Jul 17 '05 #4

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

Similar topics

0
by: Leythos | last post by:
I've searched a few sites and read a dozen things about installing PHP on IIS6, but I'm still having problems getting my PHPBB message board working. It works fine on my IIS5 server, but I want to...
4
by: Paul Schmidinger | last post by:
Hello, I have a windows-IIS-Webserver running PHP 4.3.0. However, there is no GD-Lib, so I tried to install it. What I did is this: - copy the file php_gd2.dll (which I have from another...
5
by: Grant Nosbush | last post by:
I have searched the newsgroups and the web trying to solve this problem and just can't get it. Maybe someone will be able to help. I am getting the following error when I try to view a test page...
8
by: Jeff B | last post by:
Hello, Im learning PHP along with MySql. I installed MySql with no problem and have completed several tutorials to learn it. Now when trying to use PHP code within an html page it dosn't...
2
by: y_oda2002 | last post by:
Hi everyone, I was wondering if anyone could help me. I am trying to install php so that i can learn the code. So far i havent had any problems installing apache. However when i try to get...
10
by: universalbitmapper | last post by:
Hi, I'm trying a simple form.html that call a .html script that begins with: <?php header("This is a test"); ?> When I click on the link, I get blank page.
4
by: Fensic | last post by:
Hello everyone. I am having a problem installing and configuring PHP 5.1.6. Initially I had it installed and working with Apache 2.2.3 and MySQL 5.0.24 but decided to abort and redo the...
19
by: hansBKK | last post by:
Upfront disclaimer - I am a relative newbie, just starting out learning about PHP, mostly by researching, installing and playing with different scripts. I am looking for a host that will provide...
4
by: Mr Fuzzi | last post by:
Hi All, This morning I have installed and configured Apache, MySQL and PHP on a Windows Server 2003 machine. Everything appears to be working fine, except that I keep getting an error message...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
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...
0
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,...
0
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...
0
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
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...

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.