Re: 64-bit Linux -- Fatal ... undefined function mysql_connect()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Mar 2, 2010 at 12:25 AM, Chris <dmagick@xxxxxxxxx> wrote:
> andrew jarcho wrote:
>>
>> Hello all,
>>
>> I'm running Fedora 12 (64-bit), Apache 2.2.14, PHP 5.3.1, MySQL
>> 5.1.42, on a Dell laptop.
>
> <snip>
>
>> I get the message:
>>
>> Fatal error: Call to undefined function mysql_connect()
>
> <snip>
>
>> The output of my phpinfo() includes:
>
> Is that from command line or webpage? They may read different php.ini files.
>
> # php -i | grep mysql
>
> return anything from the command line?
>
> which config is it reading?
>
> # php -i | grep php.ini
>
> Is it the one you were editing previously?
>
> --
> Postgresql & php tutorials
> http://www.designmagick.com/
>
>

Thanks *very* much to all who replied. This question has occupied most
of my time for two full days and it's a tremendous relief to know that
I'm not alone in my struggles.

As it turns out, php *was* trying to read a different .ini file when
invoked from the command line than when invoked via browser. I say
'trying to' because I had changed the name of the alternate php.ini to
'deactivate' it. I assumed that since php still worked in the browser,
I didn't need the other .ini.

I reactivated the alternate php.ini, told it the path to mysql.so, and
everything works as advertised.

I know with this version of php, I should be using mysqli.so, so
that's my next step.

Thanks again to everybody,

Andy

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux