Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- //====================
- $db_host = "localhost"; // The name of your SQL host
- $db_name = "mysite"; // The name of your database
- $db_user = "root"; // The database username
- $db_pass = ""; // The database password
- //====================
- // Connecting to the databse
- $con = mysql_connect( $db_host, $db_user, $db_pass );
- // Selecting the database
- $db = mysql_select_db( $db_name, $con );
- // Testing if the connections were made:
- if(!$con) { die("Could not connect to database."); }
- if(!$db) { die("Could not select database."); }
- //====================
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement