In linux, the mysql extension compilation of php is successful. it shows that everything in mysqlsupportyes is successful, but callundefinedfunctio is displayed on the page. how can this problem be solved?

Source: Internet
Author: User
Mysql extension compilation in php in linux successfully shows that everything in mysqlsupportyes is successful, but mysql extension compilation in php in callundefinedfunctiolinux is successful. it shows that everything in mysqlsupportyes is successful, but callundefinedfunctionmysql_connect & nb php in linux mysql extension compilation is successful. it is displayed as follows: mysql support yes, but the page calls undefined functio.
Mysql extension compilation in php in linux successfully shows that mysql support yes is successful, but the page calls undefined function mysql_connect
There is still no mysql in phpinfo (). why? Everybody

------ Solution --------------------
Is mysql-related extension enabled in the php. ini configuration file?
------ Solution --------------------
I don't know how you compile it.
-- With-mysql =/opt/mysql/server-5.5/
Note that the mysql path is added during php compilation.
If it is another compilation, mysql. so needs to be added in php. ini, but I only did this for mysqli.
------ Solution --------------------
Discussion

Reference:

I don't know how you compile it.
-- With-mysql =/opt/mysql/server-5.5/
Note that the mysql path is added during php compilation.
If it is another compilation, mysql. so needs to be added in php. ini, but I only did this for mysqli.


After the compilation is successful, will php. ini be changed?
Cp php. ini-development/usr/l ......

------ Solution --------------------
Php. ini:
Extension_dir = ". :/usr/nc-home/php5/include/php/ext:/usr/nc-home/php5/lib/php:/usr/local/lib /"
Extension =/usr/nc-home/php5/lib/php/extensions/no-debug-non-zts-20090626/hello. so
------ Solution --------------------
Extensions/no-debug-non-zts-20090626/hello. so is your compiled path. after successful compilation, there will be a path prompt to copy the last hello. so to be modified to mysql. so

You will need re2c 0.13.4 or later

Then you should go to the next new
Wget http://sourceforge.net/projects/re2c/files/re2c/0.13.5/re2c-0.13.5.tar.gz/download
Tar-zxvf re2c-0.13.5.tar.gz
Cd re2c-0.13.5
./Configure & make install

Try adding -- with-zlib-dir = .

Modify it to -- with-zlib-dir =/usr/lib.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.