See file /home/combined/public_html/protected/class/MySqlDatabase.php


+ Error on line 25

        $this->_connection mysql_connect($this->_host$this->_username$this->_password);

<?php

/*
 *  Simple MySQL facade because PDO doesn't work on webhost. 
 */
class MySqlDatabase
{
    protected 
$_host;
    protected 
$_database;
    protected 
$_username;
    protected 
$_password;
    protected 
$_connection;

    public function 
__construct($host$database$username$password)
    {
        
$this->_host $host;
        
$this->_database $database;
        
$this->_username $username;
        
$this->_password $password;
    }

    public function 
Connect()
    {
        
$this->Close();
        $this->_connection mysql_connect($this->_host$this->_username$this->_password);

        return 
mysql_select_db($this->_database$this->_connection);
    }

    public function 
Close()
    {
        if (isset(
$_connection))
        {
            
mysql_close($_connection);
            unset(
$_connection);
        }
    }

    public function 
IsConnected()
    {
        return isset(
$_connection);
    }

    public function 
Query($query)
    {
        if (!
$this->IsConnected() && !$this->Connect())
              return 
false;
        return 
mysql_query($query$this->_connection);
    }

    public function 
Errno()
    {
        return 
mysql_errno($this->connection);
    }

    public function 
Error()
    {
        return 
mysql_error($this->connection);
    }

    public function 
EscapeString($text)
    {
        if (!
$this->IsConnected() && !$this->Connect())
              return 
false;
        return 
mysql_real_escape_string($text$this->_connection);
    }

    public function 
__destruct()
    {
        
$this->Close();
    }
}

?>


* Stack Trace...

  1. /home/combined/public_html/index.php(27) calling run()
  2. /home/combined/public_html/dooframework/app/DooWebApp.php(34) calling routeTo()
  3. /home/combined/public_html/dooframework/app/DooWebApp.php(114) calling index()
  4. /home/combined/public_html/protected/controller/MainController.php(10) calling selectAll()
  5. /home/combined/public_html/protected/model/Club.php(27) calling Query()
  6. /home/combined/public_html/protected/class/MySqlDatabase.php(45) calling Connect()
  7. /home/combined/public_html/protected/class/MySqlDatabase.php(25) calling mysql_connect()


* Variables...  Conf .  GET  .  POST  .  Session  .  Cookie 


object(DooConfig)#1 (24) {
  
["AUTOLOAD"] => NULL
  
["SITE_PATH"] => string(27"/home/combined/public_html/"
  
["PROTECTED_FOLDER"] => string(10"protected/"
  
["BASE_PATH"] => string(41"/home/combined/public_html//dooframework/"
  
["LOG_PATH"] => NULL
  
["APP_URL"] => string(28"http://combinedresults.info/"
  
["SUBFOLDER"] => string(1"/"
  
["APP_MODE"] => string(3"dev"
  
["AUTOROUTE"] => bool(false)
  [
"DEBUG_ENABLED"] => bool(true)
  [
"ERROR_404_DOCUMENT"] => NULL
  
["ERROR_404_ROUTE"] => string(6"/error"
  
["CACHE_PATH"] => NULL
  
["AUTO_VIEW_RENDER_PATH"] => NULL
  
["MEMCACHE"] => NULL
  
["TEMPLATE_ENGINE"] => string(7"DooView"
  
["TEMPLATE_SHOW_COMMENT"] => NULL
  
["TEMPLATE_ALLOW_PHP"] => NULL
  
["TEMPLATE_COMPILE_ALWAYS"] => NULL
  
["TEMPLATE_GLOBAL_TAGS"] => NULL
  
["MODULES"] => NULL
  
["APP_NAMESPACE_ID"] => NULL
  
["results_db"] => array(6) {
    [
0] =>   string(9"localhost"
    
[1] =>   string(13"uspsa_results"
    
[2] =>   string(14"uspsa_afrancis"
    
[3] =>   string(10"Tse.Tung.K"
    
[4] =>   string(5"mysql"
    
[5] =>   bool(true)
  }
  [
"classifications_db"] => array(6) {
    [
0] =>   string(9"localhost"
    
[1] =>   string(20"uspsa_classification"
    
[2] =>   string(14"uspsa_afrancis"
    
[3] =>   string(10"Tse.Tung.K"
    
[4] =>   string(5"mysql"
    
[5] =>   bool(true)
  }
}
$_COOKIE Variables array(0) {
}

BACK TO TOP