Пошук по сайту
Результати пошуку за тегами 'хелппп!'.
Знайдено 1 результат
-
Добрый вечер. Хелп ми! Не работает модуль вывода на главную последних добавленных товаров на сайт. Пишет ошибку Fatal error: Class 'Controllermodulelatest' not found in /var/www/u0072430/data/www/kult.su/system/engine/controller.php on line 41 к серверу прикреплено два идентичных сайта http://www.kult.su/ и http://www.light-inside.ru/ на одном работает на втором нет, все файлы вроде пересмотрела. Там где выдает ошибку: <?php abstract class Controller { protected $registry; protected $id; protected $layout; protected $template; protected $children = array(); protected $data = array(); protected $output; public function __construct($registry) { $this->registry = $registry; } public function __get($key) { return $this->registry->get($key); } public function __set($key, $value) { $this->registry->set($key, $value); } protected function forward($route, $args = array()) { return new Action($route, $args); } protected function redirect($url, $status = 302) { header('Status: ' . $status); header('Location: ' . str_replace(array('&', "\n", "\r"), array('&', '', ''), $url)); exit(); } protected function getChild($child, $args = array()) { $action = new Action($child, $args); if (file_exists($action->getFile())) { require_once($action->getFile()); $class = $action->getClass(); $controller = new $class($this->registry); $controller->{$action->getMethod()}($action->getArgs()); return $controller->output; } else { trigger_error('Error: Could not load controller ' . $child . '!'); exit(); } } protected function render() { foreach ($this->children as $child) { $this->data[basename($child)] = $this->getChild($child); } if (file_exists(DIR_TEMPLATE . $this->template)) { extract($this->data); ob_start(); require(DIR_TEMPLATE . $this->template); $this->output = ob_get_contents(); ob_end_clean(); return $this->output; } else { trigger_error('Error: Could not load template ' . DIR_TEMPLATE . $this->template . '!'); exit(); } } } ?> 41 строка - $controller = new $class($this->registry); файлы для обеих сайтов идентичны, но на одном идет такой сбой. С чем это может быть связано? Буду признательна за подсказка и помощь в решении этого вопроса.