• Plesk Uservoice will be deprecated by October. Moving forward, all product feature requests and improvement suggestions will be managed through our new platform Plesk Productboard.
    To continue sharing your ideas and feedback, please visit features.plesk.com

Connot connect MySQL

J

joezine

Guest
> I have some problem about php-mysql connection.
>
> I coded basicly php to connect with MySQL. This is code,
>
> $connect = mysql_connect("xxx.xxx.com", "user", "password")
> or die("die");
>
>
> * I cannot reveal my user and password but it's correct cause I can
> enter to mysql by this user and password.
>
>
>
> This is the result.
>
>
> Fatal error: Call to undefined function: mysql_connect() in
> /var/www/vhosts/xxxx.xxxxx.com/httpdocs/pontus.php on line 3
>
>
> I try to rpm -q php-mysql. It shows that "php-mysql-4.3.9-3.8".
>
> I try to "telnet xxx.xxx.com 3306". It shows that
>
> Trying 202.xxx.xx.xxx...
> Connected to xxx.xxx.com (202.xxx.xx.xxx).
> Escape character is '^]'.
> .
> 4.0.23-nt-logb}p:eek:C>L,
>
>
> It refer to the successful connection.
>
>
>
> Please suggest me.
 
I try "php -m". It shows as below.

[PHP Modules]
bcmath
bz2
calendar
ctype
curl
dba
dbx
dio
domxml
exif
ftp
gd
gettext
gmp
iconv
imap
ionCube Loader
ldap
mime_magic
mysql
openssl
overload
pcntl
pcre
pgsql
posix
pspell
session
shmop
sitebuilder
sockets
standard
sysvsem
sysvshm
tokenizer
wddx
xml
yp
zip
zlib

[Zend Modules]
the ionCube PHP Loader


I try "rpm -qa | grep php". It shows as below.

php-ldap-4.3.9-3.8
php-mysql-4.3.9-3.8
php-domxml-4.3.9-3.8
phpBB-2.0.17-7518
phpMoney-1.3-7510
php-4.3.9-3.8
php-pear-4.3.9-3.8
php-pgsql-4.3.9-3.8
php-imap-4.3.9-3.8
phpAds-2.0.5-7506
phpBook-1.50-7507
phpDig-1.85-7505
phpMyFamily-1.4.1-7508
phpWiki-1.3.11-7508
php-ioncube-loader-1.0-rhel4.build051222.05
php-gd-4.3.9-3.8
phpBugTracker-1.19-7506
phpsurveyor-0.98-7510



You can see the error at http://webpilot1.cslox.com/pontus.php and phpinfo at http://webpilot1.cslox.com/php.php
 
Back
Top