Hi, I have PHP 4.3.0 installed on a Red Hat system. I have written a number of command line scripts which run perfectly fine. For example
<u.php> #! /usr/bin/php -q <? $conn = mysql_connect($host, $user, $pass) or die('cannot connect'); // do my stuff ?> </u.php> This script works perfectly fine, when started from the command line. Now i intend to call this command line script from another another script (that is called from the browser). for example - < /var/www/html/test.php > <? $script = '/usr/local/bin/u.php'; $response = `{$script}`; echo $response; ?> </ /var/www/html/test.php > This generates an error ' Fatal error : Call to undefined function: mysql_connect() in /usr/local/bin/u.php on line 3' phpinfo gives me the following cofigure command './configure' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' '--prefix=/usr' '--with-config-file-path=/etc' '--disable-debug' '--with-pic' '--disable-rpath' '--enable-inline-optimization' '--with-bz2' '--with-exec-dir=/usr/bin' '--with-freetype-dir=/usr' '--with-gd' '--with-gdbm' '--with-gettext' '--with-jpeg-dir=/usr' '--with-mm' '--with-openssl' '--with-png' '--with-regex=system' '--with-ttf' '--with-xml' '--with-expat-dir=/usr' '--with-zlib' '--with-layout=GNU' '--enable-bcmath' '--enable-debugger' '--enable-ftp' '--enable-magic-quotes' '--enable-safe-mode' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-track-vars' '--enable-yp' '--enable-wddx' '--with-ldap=shared' '--with-mysql=shared' '--with-apxs=/usr/sbin/apxs' Thank you to all With regrads gamin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php