Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- class conection{
- public $_host;
- public $_user;
- public $_pass;
- public $_db;
- function __construct($host,$user,$pass,$db){
- $this->_host = $host;
- $this->_user =$user;
- $this->_pass = $pass;
- $this->_db =$db;
- self::conectar();
- }
- public function conectar(){
- $conexao = mysql_connect($this->_host,$this->_user,$this->_pass);
- mysql_select_db($this->_db, $conexao);
- }
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement