I'm using LAMPP with Ubuntu 64 bit. When I try to execute php file using terminal,undefined mysql_connect error is given.But everything works fine when I'm using browser to load my php file. I tried to edit the php.ini with remove the semicolon in front of extension=mysql.so then restart lampp,but with a error "unable to load dynamic library". What can I do to solve this problem? This is important for me because I need to run my php script using crontab.
PHP Fatal error: Call to undefined function mysql_connect() in /opt/lampp/htdocs/setrandomport-message.php on line 15
PHP Startup: Unable to load dynamic library '/opt/lampp/lib/php/extensions/no-debug-non-zts-20090626/msql.so' - /opt/lampp/lib/php/extensions/no-debug-non-zts-20090626/msql.so: cannot open shared object file: No such file or directory in Unknown on line 0