Re[2]: [PHP] Connecting to MySQL database

From: Date: Fri, 08 Jun 2001 13:54:25 +0000
Subject: Re[2]: [PHP] Connecting to MySQL database
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-70356@lists.php.net to get a copy of this message
Hello David, DO> I /really/ don't want to make the database connector global here, DO> that's a nasty solution. MySQL can certainly handle multiple open DO> connections... how do I create them at the PHP end? MySQL can handle multiple connections, but please, read PHP manual before. Quote from mysql_connect() man page: "If a second call is made to mysql_connect() with the same arguments, no new link will be established, but instead, the link identifier of the already opened link will be returned. " IMHO, you need a middle-layer for database functions between your functions and mysql_* functions. This layer should handle database connections, queries, etc. -- Best regards, Vitali mailto:falileev@itos.eu.org

« previous php.general (#70356) next »