Created
August 21, 2014 09:13
-
-
Save rikardhassel/616d6694474baa0e5f0f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Private function connect() | |
* This function is the basic code for the call to mySQLi. Returns a link to server. | |
* @return object | |
*/ | |
private function connect() | |
{ | |
$link = new mysqli( $GLOBALS['db_host'], $GLOBALS['db_user'], $GLOBALS['db_pass'], $GLOBALS['db_db'] ) or die( mysqli_error( $link ) ); | |
$link->set_charset( 'utf8' ); | |
return $link; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment