note 48736 rejected from function.mysql-connect by cece
| From: | cece@php.net | Date: | Wed, 05 Jan 2005 21:10:46 +0000 |
| Subject: | note 48736 rejected from function.mysql-connect by cece | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-82797@lists.php.net to get a copy of this message | ||
Note Submitter: carefree at online dot de
----
Hello, i was wondering if you could tell something about the code below.
Is this a correct database connection? I mean, would professionals use it?
<?php
$server = "localhost";
$database = "db";
$user = "";
$pass = "";
$connect = mysql_connect($server) or die(mysql_error());
$db = mysql_select_db($database, $connect) or die(mysql_error());
?>
Greetings
carefree