31($this->config_php_file->get('dbms'));
/** @var \phpbb\db\driver\driver_interface $dbal_connection */
$this->dbal_connection = new $dbal_driver_class();
$this->dbal_connection->sql_connect(
$this->config_php_file->get('dbhost'),
$this->config_php_file->get('dbuser'),
$this->config_php_file->get('dbpasswd'),
$this->config_php_file->get('dbname'),
$this->config_php_file->get('dbport'),
false,
defined('PHPBB_DB_NEW_LINK') && PHPBB_DB_NEW_LINK
);
}
$this->container->set('dbal.conn.driver', $this->dbal_connection);
}
}
/**
* Returns the core parameters.
*
* @return array An array of core parameters
*/
protected function get_core_parameters()
{
return array_merge(
array(
'core.root_path' => $this->phpbb_root_path,
'core.php_ext' => $this->php_ext,
'core.environment' => $this->get_environment(),
'core.debug' => defined('DEBUG') ? DEBUG : false,
'core.cache_dir' => $this->get_cache_dir(),
),
$this->get_env_parameters()
);
}
/**
* Gets the environment parameters.
*
* Only the parameters starting with "PHPBB__" are considered.
*
* @return array An array of parameters
*/
protected function get_env_parameters()
{
$parameters = array();
foreach ($_SERVER as $key => $value)
{
if (0 === strpos($key, 'PHPBB__'))
{
$parameters[strtolower(str_replace('__', '.', substr($key, 9)))] = $value;
}
}
return $parameters;
}
/**
* Get the filename under which the dumped container will be stored.
*
* @return string Path for dumped container
*/
protected function get_container_filename()
{
$container_params = [
'phpbb_root_path' => $this->phpbb_root_path,
'use_extensions' => $this->use_extensions,
'config_path' => $this->config_path,
];
return $this->get_cache_dir() . 'container_' . md5(implode(',', $container_params)) . '.' . $this->php_ext;
}
/**
* Get the filename under which the dumped extensions autoloader will be stored.
*
* @return string Path for dumped extensions autoloader
*/
protected function get_autoload_filename()
{
$container_params = [
'phpbb_root_path' => $this->phpbb_root_path,
'use_extensions' => $this->use_extensions,
'config_path' => $this->config_path,
];
return $this->get_cache_dir() . 'autoload_' . md5(implode(',', $container_params)) . '.' . $this->php_ext;
}
/**
* Return the name of the current environment.
*
* @return string
*/
protected function get_environment()
{
return $this->environment ?: PHPBB_ENVIRONMENT;
}
private function register_ext_compiler_pass()
{
$finder = new Finder();
$finder
->name('*_pass.php')
->path('di/pass')
->files()
->ignoreDotFiles(true)
->ignoreUnreadableDirs(true)
->ignoreVCS(true)
->followLinks()
->in($this->phpbb_root_path . 'ext')
;
/** @var \SplFileInfo $pass */
foreach ($finder as $pass)
{
$filename = $pass->getPathname();
$filename = substr($filename, 0, -strlen('.' . $pass->getExtension()));
$filename = str_replace(DIRECTORY_SEPARATOR, '/', $filename);
$className = preg_replace('#^.*ext/#', '', $filename);
$className = '\\' . str_replace('/', '\\', $className);
if (class_exists($className) && in_array('Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface', class_implements($className), true))
{
$this->container->addCompilerPass(new $className());
}
}
}
}
Fatal error: Uncaught Error: Class 'phpbb\di\container_builder' not found in /home/acumstiu/gpszone.ro/common.php:114
Stack trace:
#0 /home/acumstiu/gpszone.ro/viewforum.php(20): include()
#1 {main}
thrown in /home/acumstiu/gpszone.ro/common.php on line 114