Posted By

mzym on 09/22/09


Tagged

mysql php queries kickstart


Versions (?)

access.inc


 / Published in: PHP
 

  1. $host="";
  2. $user="";
  3. $pw="";
  4. $db="";
  5.  
  6. function MySQL_GetReady($host, $user, $pw, $db)
  7. {
  8. $ret = mysql_connect($host, $user, $pw)
  9. or die("Error in <b>MySQL_GetReady</b> while <i>mysql_connect()</i>");
  10. or die("Datenbank nicht gefunden!");
  11. return $ret;
  12. }
  13.  
  14. MySQL_GetReady($host, $user, $pw, $db);
  15.  
  16. mysql_query('SET NAMES utf8');
  17. mysql_query("SET CHARACTER SET utf8");

Report this snippet  

You need to login to post a comment.