Re: [PHP-DB] undefined function Mysql_connect()
I am running Windows XP PRO, Appache 2.0 PHP 5.2.5 as a module, Did you install the php-mysql module too ? http://www.php.net/manual/en/ref.mysql.php Look under the Installation on Windows Systems section. -- Postgresql php tutorials http://www.designmagick.com/ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] undefined function error
from the php manual [quote] This MySQL extension doesn't support full functionality of MySQL versions greater than 4.1.0. For that, use MySQLi. [/quote] http://ca3.php.net/manual/en/ref.mysqli.php bastien From: Chip Wiegand [EMAIL PROTECTED] To: PHP DB php-db@lists.php.net Subject: [PHP-DB] undefined function error Date: Fri, 18 Mar 2005 13:53:08 -0800 I have a web site that connects to a mysql database using this connect script - ? $db=mysql_connect(localhost,***,***); mysql_select_db(simradusa,$db); ? When I access the page it gives me this error - Fatal error: Call to undefined function: mysql_connect() in /usr/local/www/data-dist/connect on line 1 Using mysql-4.1.10a for FreeBSD-5.3 with php-4.3.9 Any idea why I'm getting this error? (the same connect string works fine on a differant web server running FreeBSD-5.2.1/php-4.3.6/mysql-3.23.49) Thanks, Chip -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] undefined function error
It could be possible that mySQL is not enabled in your installation of PHP. Let the server parse a page with phpinfo() in it and read the results. Look for mySQL enabled. Perhaps the reason it runs fine on another server is that the php on that server has mysql enabled. HTH, Mark Cain - Original Message - From: Chip Wiegand [EMAIL PROTECTED] To: PHP DB php-db@lists.php.net Sent: Friday, March 18, 2005 4:53 PM Subject: [PHP-DB] undefined function error I have a web site that connects to a mysql database using this connect script - ? $db=mysql_connect(localhost,***,***); mysql_select_db(simradusa,$db); ? When I access the page it gives me this error - Fatal error: Call to undefined function: mysql_connect() in /usr/local/www/data-dist/connect on line 1 Using mysql-4.1.10a for FreeBSD-5.3 with php-4.3.9 Any idea why I'm getting this error? (the same connect string works fine on a differant web server running FreeBSD-5.2.1/php-4.3.6/mysql-3.23.49) Thanks, Chip -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] undefined function
OK, I added it!! But it still does work. BTW, I have four different PHP.ini files in my system, where I can see which one is using it? I added it to all of them!! IIS PHP 4.x SQL Server Miguel Guirao Servicios Datacard www.SIASA.com.mx -Mensaje original- De: Bruno Ferreira [mailto:[EMAIL PROTECTED] Enviado el: Viernes, 21 de Mayo de 2004 05:01 p.m. Para: [EMAIL PROTECTED] Asunto: Re: [PHP-DB] undefined function Miguel Guirao wrote: First, I do not have that line in my php.ini file. In what section should I add it? Anywhere, but best place as long as organization is concerned would be under the Dynamic extensions label. Bruno Ferreira PS - You should check the default php.ini that comes with your PHP distribution and customize from there. --- [This E-mail scanned for viruses by Declude Virus] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] undefined function
From: Miguel Guirao [EMAIL PROTECTED] BTW, I have four different PHP.ini files in my system, where I can see which one is using it? I added it to all of them!! phpinfo() will product a page that shows you what php.ini file PHP is using. It's in the first block. ---John Holmes... -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] undefined function
Thank you everybody!! I was missing that bloody dll. Is working now!!! Best Regards, and thanks again Miguel Guirao Servicios Datacard www.SIASA.com.mx -Mensaje original- De: John W. Holmes [mailto:[EMAIL PROTECTED] Enviado el: Lunes, 24 de Mayo de 2004 01:06 p.m. Para: Miguel Guirao; 'Bruno Ferreira'; [EMAIL PROTECTED] Asunto: Re: [PHP-DB] undefined function From: Miguel Guirao [EMAIL PROTECTED] BTW, I have four different PHP.ini files in my system, where I can see which one is using it? I added it to all of them!! phpinfo() will product a page that shows you what php.ini file PHP is using. It's in the first block. ---John Holmes... -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] undefined function
Miguel Guirao wrote: I'm receiving this error: Fatal error: Call to undefined function: mssql_connect() in e:\inetpub\wwwroot\sitio\TMP5w3gxy2pnf.php on line 9 This is line 9:if (!( $con = mssql_connect($maquina, $usuario, $password))) $maquina = SERVIDOR; $usuario = sa; $password = ; $BDnombre = ProyectoRMA; So, basically, any ideas of the source of this error? Probably the mssql extension isn't loaded. Open the php.ini file and see that the line reading extension=php_mssql.dll isn't commented out. Things should go back to normal. Bruno Ferreira --- [This E-mail scanned for viruses by Declude Virus] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] undefined function
First, I do not have that line in my php.ini file. In what section should I add it? I forgot, I'm using Windows 2000 Server, SQL Server, PHP4 and coding in DreamweaverMX Miguel Guirao Servicios Datacard www.SIASA.com.mx -Mensaje original- De: Bruno Ferreira [mailto:[EMAIL PROTECTED] Enviado el: Viernes, 21 de Mayo de 2004 02:39 p.m. Para: [EMAIL PROTECTED] Asunto: Re: [PHP-DB] undefined function Miguel Guirao wrote: I'm receiving this error: Fatal error: Call to undefined function: mssql_connect() in e:\inetpub\wwwroot\sitio\TMP5w3gxy2pnf.php on line 9 This is line 9:if (!( $con = mssql_connect($maquina, $usuario, $password))) $maquina = SERVIDOR; $usuario = sa; $password = ; $BDnombre = ProyectoRMA; So, basically, any ideas of the source of this error? Probably the mssql extension isn't loaded. Open the php.ini file and see that the line reading extension=php_mssql.dll isn't commented out. Things should go back to normal. Bruno Ferreira --- [This E-mail scanned for viruses by Declude Virus] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] undefined function
Miguel Guirao wrote: First, I do not have that line in my php.ini file. In what section should I add it? Anywhere, but best place as long as organization is concerned would be under the Dynamic extensions label. Bruno Ferreira PS - You should check the default php.ini that comes with your PHP distribution and customize from there. --- [This E-mail scanned for viruses by Declude Virus] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] Undefined function mysql_connect
On Monday 05 January 2004 11:55, Richard Bewley wrote: I compiled mySQL 4.0.16 from source, and installed PHP 4 off the RH9 cd. I also have the php-mysql-4.2.2-17 rpm installed. But for some reason, I keep getting call to undefined function mysql_connect, and it won't connect to the mysql database. Any ideas? Either install both from source or both from RPMs. The file locations and default configs used by RH can be different from the bog-standard mysql install so there lies your problem. I recommend that you install mysql from the official rpms and apache/php from source. That way everything can be updated without relying on RH. -- Jason Wong - Gremlins Associates - www.gremlins.biz Open Source Software Systems Integrators * Web Design Hosting * Internet Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-db -- /* Love sometimes expresses itself in sacrifice. -- Kirk, Metamorphosis, stardate 3220.3 */ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] undefined function: mysql_pconnect()
Could you post your entire script to see what's wrong ? -Message d'origine- De : Cameron [mailto:[EMAIL PROTECTED] Envoyé : samedi 1 mars 2003 6:17 À : [EMAIL PROTECTED] Objet : [PHP-DB] undefined function: mysql_pconnect() I'm new to this stuff, so you have to excuse me if I seem dense. I can't get MySQL base operation from PHP 4.22 under RedHat Linux 8.0. I get the following error when trying to use mysql_connect(). Call to undefined function: mysql_pconnect() I don't have any other PHP running on the box, other non-db related scripting works. I'm using Apache 2.0, all the newest stuff. The PHP documentation says this should be built in, and when I utilize phpinfo(), the output section dbx says MySQL is installed. Can someone help me out? Thanks... Signed, someone who spent his time in ASP but wants out. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] undefined function: mysql_pconnect()
on 3/1/03 12:16 AM, Cameron at [EMAIL PROTECTED] appended the following bits to my mbox: I'm new to this stuff, so you have to excuse me if I seem dense. I can't get MySQL base operation from PHP 4.22 under RedHat Linux 8.0. I get the following error when trying to use mysql_connect(). Call to undefined function: mysql_pconnect() You need to install the php-MySQL RPM file from the Red Hat CD. The default install doesn't give you MySQL support. HTH. Sincerely, Paul Burney -- I'm inhaling Caesar's last gasp... http://paul.burney.ws/thoughts/caesars_breath.html -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] undefined function: mssql_connect()
Hi With PHP 4.3.0 you can use --with-mssql (it looks for freetds in /usr/local/freetds by default). Then you can use the mssql.* settings in php.ini. When you compile using --with-sybase you would have to use the sybase.* settings in php.ini, as that is the extension you would be using. You should not use ip:port as your host name. Port 1433 is the default for both MSSQL and FreeTds. If you use any other port number you should specify this in freetds.conf. - Frank Hi there, Hope someone can help me with this. I need to connect to a MS SQL database but my attemps fail once and again. This is the error message I get when try to connect: Fatal error: Call to undefined function: mssql_connect() in /var/www/htdocs/DB_conn.php on line 8 The script is very simple: ?php $hostname = 10.0.0.206:1433; $username = sa; $password = ; $dbName = dbname_here; $idLink = mssql_connect($hostname,$username,$password) or die(DATABASE FAILED TO RESPOND.); mssql_select_db($dbName) or die(Table unavailable); ? Now, this is the info I can provide: 1) PHP version 4.3.0-dev 2) phpinfo shows: './configure' '--prefix=/usr/local' '--enable-module=so' '--with-mod_charset' '--enable-sockets' '--enable-memory-limit' '--with-sybase=/usr/local/freetds' 3) Of course, freetds is located at /usr/local/freetds and works properly. It was tested using tsql -H -p -U and it's ok. 4) I also tried adding #!/usr/local/bin/php to try it as a shell scripting thing and it WORKS! Which is very confusing. 5) php.ini shows: [MSSQL] ; Allow or prevent persistent links. mssql.allow_persistent = On ; Maximum number of persistent links. -1 means no limit. mssql.max_persistent = -1 ; Maximum number of links (persistent+non persistent). -1 means no limit. mssql.max_links = -1 ; Minimum error severity to display. mssql.min_error_severity = 10 ; Minimum message severity to display. mssql.min_message_severity = 10 ; Compatability mode with old versions of PHP 3.0. mssql.compatability_mode = Off ; Valid range 0 - 2147483647. Default = 4096. ;mssql.textlimit = 4096 ; Valid range 0 - 2147483647. Default = 4096. ;mssql.textsize = 4096 ; Limits the number of records in each batch. 0 = all records in one batch. ;mssql.batchsize = 0 ; Use NT authentication when connecting to the server mssql.secure_connection = Off ; Specify max number of processes. Default = 25 ;mssql.max_procs = 25 I have no idea what the problem is; any help will be much appreciated. -Paula mail2web - Check your email from the web at http://mail2web.com/ . -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] undefined function
N Fatal error: Call to undefined function: mysql_connect() in N /var/www/html/action.php on line 13 This indicates you do not have MySQL support built into PHP. Assuming a non-Windows OS by the pathnames above, you must use --with-mysql when issuing the configure command when building PHP. - Julie -- Julie Meloni -- [EMAIL PROTECTED] -- www.thickbook.com Find Sams Teach Yourself MySQL in 24 Hours at http://www.amazon.com/exec/obidos/ASIN/0672323494/thickbookcom-20 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] undefined function
Hi: thank you for you e mail I am using redhat7.2 I am new to php and linux , do not know how to configure mysql into php I wrote a simple function to ask the user for two numbers and add them together and print them out, and it worked. But when I used predefined function, I get the error. where do I go from here? Thanks - Original Message - From: Julie Meloni [EMAIL PROTECTED] To: Nick [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Tuesday, April 09, 2002 9:44 AM Subject: Re: [PHP-DB] undefined function N Fatal error: Call to undefined function: mysql_connect() in N /var/www/html/action.php on line 13 This indicates you do not have MySQL support built into PHP. Assuming a non-Windows OS by the pathnames above, you must use --with-mysql when issuing the configure command when building PHP. - Julie -- Julie Meloni -- [EMAIL PROTECTED] -- www.thickbook.com Find Sams Teach Yourself MySQL in 24 Hours at http://www.amazon.com/exec/obidos/ASIN/0672323494/thickbookcom-20 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] undefined function
On Wednesday 10 April 2002 00:12, Nick wrote: Hi: thank you for you e mail I am using redhat7.2 I am new to php and linux , do not know how to configure mysql into php Install: php-mysql-4.0.6-7.i386.rpm it's on the second disc. -- Jason Wong - Gremlins Associates - www.gremlins.com.hk Open Source Software Systems Integrators * Web Design Hosting * Internet Intranet Applications Development * /* Lying is an indispensable part of making life tolerable. -- Bergan Evans */ -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php