Advertisement
Guest User

Untitled

a guest
Feb 3rd, 2017
161
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. $this->db_host = $datos_conexion['db_host'];
  2. $this->db_user = $datos_conexion['db_user'];
  3. $this->db_pass = $datos_conexion['db_pass'];
  4. $this->db_name = $datos_conexion['db_name'];
  5. $this->db_charset = $datos_conexion['db_charset'];
  6.  
  7. $this->connection = new mysqli($this->db_host, $this->db_user, $this->db_pass, $this->db_name);
  8. if(!$this->connection){
  9. throw new ExceptionSicatsem("Error al intentar conectar con la base de datos");
  10. }else {
  11. $this->connection->set_charset($this->db_charset);
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement