mirror of
https://github.com/RustyRaptor/Culidore.git
synced 2026-12-03 15:15:20 -07:00
21 lines
505 B
PHP
21 lines
505 B
PHP
<?php
|
|
|
|
// this will avoid mysql_connect() deprecation error.
|
|
error_reporting( ~E_DEPRECATED & ~E_NOTICE );
|
|
// but I strongly suggest you to use PDO or MySQLi.
|
|
|
|
define('DBHOST', 'localhost');
|
|
define('DBUSER', 'root');
|
|
define('DBPASS', '');
|
|
define('DBNAME', 'dbtest');
|
|
|
|
$conn = mysql_connect(DBHOST,DBUSER,DBPASS);
|
|
$dbcon = mysql_select_db(DBNAME);
|
|
|
|
if ( !$conn ) {
|
|
die("Connection failed : " . mysql_error());
|
|
}
|
|
|
|
if ( !$dbcon ) {
|
|
die("Database Connection failed : " . mysql_error());
|
|
} |