LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   lamp setup question about php extension for mysql (https://www.linuxquestions.org/questions/linux-software-2/lamp-setup-question-about-php-extension-for-mysql-541585/)

rlee923 03-29-2007 06:26 AM

lamp setup question about php extension for mysql
 
Hi,

I've downloaded all the lastest release of each

apache2, mysql, and php

and configured-them properly,(i think...sigh*)

and installed.

They all work fine seperately,

but when I tried to look and phpinfo()

it doens't show me the mysql setup configureation even though
I've configured php with

--with-mysql-dir=/usr/local/mysql

What I've done so far is I've compiled apache2 first

and then mysql

and then php.

I heard that php does not include mysql extension by default but
I read something before it said the extension should be installed when i put that --with-mysql-dir

Can someone let me know what' I've done wrong?

Cheers

benjithegreat98 03-29-2007 10:40 AM

In your php.ini file do you see a line that says:
extension=php_mysql.dll

If there is a semicolon in front of it that means it is commented out.

If it isn't there at all maybe you could try adding it.

rlee923 03-29-2007 07:42 PM

Errr... I thought that was just for Windows. I am currently using FC6
correct me if not.

Thanks for the reply.

Cheers

benjithegreat98 03-29-2007 08:06 PM

OOPS!! Sorry, I wasn't thinking. I had wamp installed on my work laptop and didn't even consider the windows/linux diff.

Anyway, here's a thread that may help you out...
http://www.phpbuilder.com/board/show...php?t=10302059

benjithegreat98 03-29-2007 09:08 PM

Also, I was curious if there was a reason you were compiling them from source instead of installing the pre-built RPMs.

rlee923 03-29-2007 09:32 PM

Thanks for the speedy reply.

It's because I am going to do lamp setup on a different machine that is not mine for the company and I do not know which linux we are going to put on.

So I should know the distro-independent setup for the time being, since they might put something that's non-popular.

Cheers

rlee923 03-29-2007 10:20 PM

Hmm. Looks like this thread is about problems when you do configure.

I have no problems with configuration itself(now, that is. I had problem before because I did not know that the option for the configuration is --with-mysql-dir not --with-mysql).

The problem I am having is that I cannot call any mysql functions and I don't see the configuration of mysql on the phpinfo() even though I did put --with-mysql-dir.(In other words, I cannot connect to db with php script)

I did see mysqlclient.so or something while I was doing configuration of php.

I am currently at work so I can't try to reconfigure php at the moment(FC6 is on my laptop), but I'll let you know once I get home and try as shown on the link.

Cheers

rlee923 04-01-2007 11:13 PM

This problem is resolved by setting the path on the include section of php.ini


All times are GMT -5. The time now is 01:38 AM.