Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
08-19-2003, 12:51 PM
|
#1
|
LQ Newbie
Registered: Aug 2003
Location: Mexico, Allende, N.L.
Distribution: Red Hat Linux 9
Posts: 19
Rep:
|
PHP Problem in RHL9
Hello guys, can anybody help me please ?
One month ago I installed RHL 9 in two of my pcs and I'm reading every piece of information I can get.
The fact is: I recently bought a book titled "PHP and MySQL Web Development" to learn to program in PHP (ovbious). The problem is that when I follow the instructions on installation, I get everyting to work except PHP. When i create a test.php file with <?php phpinfo(); ?> function it doesn't give the page with info it should give.
The book guides to install explicit versions of the software, but this versions are not longer available so I replaced them with a sligtly newer ones.
I installed this:
MySQL-3.23.57-1.i386.rpm
MySQL-client-3.23.57-1.i386.rpm
MySQL-devel-3.23.57-1.i386.rpm
MySQL-Max-3.23.57-1.i386.rpm
MySQL-shared-3.23.57-1.i386.rpm
pdflib-4.0.3.tar.gz
curl-7.10.7.tar.gz
apache_1.3.28.tar.gz
php-4.3.2.tar.gz
openssl-0.9.6g
mod_ssl-2.8.15-1.3.28
and followed every instruction on installing, replacing the apropiated name when necessary. Everyting worked (and was tested) as said by the book, except PHP. Even tried the following code as recomended in the php official manual (in a file called test.php in the apropiated directory (htdocs)):
<html>
<head>
<title>Example</title>
</head>
<body>
<?php
echo "Hi, I'm a PHP script!";
?>
</body>
</html>
I can see the text on top of the browser, i mean, the html tags work, but not the php code. I have stoped the apache work and then restarted it; Have tried reinstalling php, and NO, it doesn't work.
I installed the software on another pc, and no, it doesn't work.
HELP PLEASE !!!
|
|
|
08-19-2003, 12:53 PM
|
#2
|
Member
Registered: Apr 2003
Distribution: Gentoo 1.4
Posts: 290
Rep:
|
make sure you built php IN to apache and that its enabled
|
|
|
08-19-2003, 01:13 PM
|
#3
|
LQ Newbie
Registered: Aug 2003
Location: Mexico, Allende, N.L.
Distribution: Red Hat Linux 9
Posts: 19
Original Poster
Rep:
|
This is what i did when installing...
gunzip -c apache_1.3.28.tar.gz | tar xvf -
cd apache_1.3.28
./configure --prefix=/usr/local/apache
then....
cd /usr/src
gunzip -c php-4.3.2.tar.gz | tar xvf -
cd php-4.3.2
./configure --with-mysql=/usr --with-xml --with-apache=../apache_1.3.28 --with-curl=../curl --enable-shared-pdflib
make
make install
cp php.ini-dist /usr/local/lib/php.ini
(Installed openssl-0.9.6g and mod_ssl-2.8.15-1.3.28)
Then
cd ../apache_1.3.28
SSL_BASE=../openssl-0.9.6g ./configure --enable-module=ssl --activate-module=src/modules/php4/libphp4.a --enable-module=php4 --prefix=/usr/local/apache --enable-shared-ssl
make
make certificate TYPE=custom
make install
and then modified httpd.conf adding:
# And for PHP 4.x, use:
#
AddType application/x-httpd-php .php
AddType application/x-httpd-hph-source .phps
|
|
|
08-19-2003, 03:25 PM
|
#4
|
LQ Newbie
Registered: Aug 2003
Location: Mexico, Allende, N.L.
Distribution: Red Hat Linux 9
Posts: 19
Original Poster
Rep:
|
I forgot to tell that both computers I have linux installed in, were installed as desktop, No Server or Workstation.... żis it important or not?
Last edited by viccavazos; 08-19-2003 at 03:31 PM.
|
|
|
08-22-2003, 07:58 PM
|
#5
|
Member
Registered: Apr 2002
Location: Los Gatos, CA
Distribution: boring redhat 9
Posts: 163
Rep:
|
I can't seem to find any error with your installation, other than the insignificant (to this issue) typo of having "hph-source" in the conf file.
Normally I would say use source whenever possible, like you have. In this instance however, pop in your RH9 disc 1, open the package manager and install PHP+HTTPD in the "Web Server" section. For the purposes of learning php, it will get you going in the direction you desire.
Kudos on the choice of books. I learned a LOT of stuff from one of the older editions of that book.
|
|
|
08-25-2003, 12:12 PM
|
#6
|
LQ Newbie
Registered: Aug 2003
Location: Mexico, Allende, N.L.
Distribution: Red Hat Linux 9
Posts: 19
Original Poster
Rep:
|
Thank you very much for your time Saraev !!!
I actually could install and get to work all three MySQL, Apache and PHP following the instructions given in www.devside.net, it took me saturday from 8:30 am to 1:40 pm, but thanks to the guys from devside, now I have my linux box working with those packages and I'm willing to learn to program in PHP and develop something in the near future.
Now, if anybody have a question about the instructions given in devside (if you are going to install in RH9) maybe I can help with the experience I get following them, just post here.
|
|
|
All times are GMT -5. The time now is 05:38 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|