title: Installing my script in localhost and get error
body: <p>I have a script that installed on web host but when I want to install and run it on localhost get this error:</p>
  
  <pre><code>setLogPath($config['debugger_log_dir']);
   $debugger-&gt;setDebuggerTemplates($config['debugger_template_dir']);
   //Start debugger timer $debugger-&gt;measureRunTime();
   // Initialize db object for the queries $db = new Database($db_config);
   //Start settings autocreater $SettingsParser = new SettingsParser(ROOT_PATH . "core/3WFW/Settings.php",&amp;$config);
   $settings = $SettingsParser-&gt;load();
   /* if($settings['setting_site_status'] == 'offline'){ $ips = $db-&gt;fetchAll("SELECT * FROM `allow_ips`");
   $rIps = array();
   foreach($ips AS $k=&gt;$v){ $rIps[] = $v['ip'];
   } if(!in_array($_SERVER['REMOTE_ADDR'], $rIps)){ echo $settings['setting_offline_message'];
   exit();
   } } */ //set timezone ini_set('date.timezone', $settings['setting_server_timezone']);
   //set cookies session_set_cookie_params($settings['setting_cookie_lifetime']);
   session_regenerate_id();
   //    Start the template system $smarty = new Smarty();
   //$smarty-&gt;template_dir = ROOT_PATH . 'application/templates/'. $settings['setting_site_skin'] . '/';
   $smarty-&gt;compile_dir = ROOT_PATH . 'temp/cache_template/';
   $smarty-&gt;config_dir = ROOT_PATH . 'temp/cache_template/';
   $smarty-&gt;cache_dir = ROOT_PATH . 'temp/cache/';
   $smarty-&gt;debugging = false;
   $smarty-&gt;caching = $settings['setting_smarty_cache_status'];
   $smarty-&gt;compile_check = true;
   $smarty-&gt;cache_lifetime = $settings['setting_smarty_cache_lifetime'];
   // Start the cache system Loader::loadClass("Cache");
   // Find Out what the user is using Loader::loadClass("Browser");
   $settings['browser'] = Browser::detect();
   // Start the registry Registry::set($db, "db");
   Registry::set($smarty, "smarty");
   Registry::set($debugger, "debugger");
   Registry::set($config, "config");
   Registry::set($settings, "settings");
   Registry::set(new Cache($cache), "cache");
   isset($_SESSION['admin_lang']) ? $admin_lang = $_SESSION['admin_lang'] : $admin_lang = $settings['setting_admin_lang'];
   Registry::set(Language::loadAdmin($admin_lang), "adminlang");
   isset($_SESSION['front_lang']) ? $front_lang = $_SESSION['front_lang'] : $front_lang = $settings['setting_front_lang'];
   Language::initFront($front_lang);
   //    Registry::set(Language::loadFront($front_lang), "frontlang");
   Registry::set(Language::loadFront(), "frontlang");
   //Load SEO Router "OPTIONAL!" Loader::loadClass("Router");
   //Load CMS pages $cms = array('about','careers','faq','payment-methods','terms','privacy- policy','join',' checkoutsucc','checkoutfail','about-us');
   $cms_all = $db-&gt;fetchAll("SELECT url FROM cms_page WHERE menu IN ('aboutus', 'aboutyou', 'aboutbusiness','no-menu')");
   foreach($cms_all as $v){ if(!in_array($v['url'], $cms)) $cms[] = $v['url'];
   } $cms = implode('|', $cms);
   $seo_rules['cms']['pattern'] = "/\/({$cms})/i";
   //Start controller system $controller = new Controller();
   $controller-&gt;start(Router::checkURL($seo_rules));
   //    end time for script $debugger-&gt;measureRunTime();
   // Show //debugger if(false){ if(in_array($_SERVER['REMOTE_ADDR'], $config['developers_ips']) AND empty($_POST)){ $db-&gt;showSQLDebugger();
   $debugger-&gt;show_debugger();
   } } ?&gt;
  </code></pre>
  
  <p>I edit db username and password correctly and I install that on web host but in local cant run it. can you help me?</p>