CHttpException

Страница не найдена

/home/p364072/public_html/protected/controllers/ShopController.php(347)

335             Yii::app()->end();
336         } else {
337             $categories = Category::model()->findAll(array('order' => 'ordering'));
338             $this->render('shop', compact('categories', 'products', 'title'));
339         }
340     }
341 
342     public function actionCategory($id)
343     {
344         $category = Category::model()->findByPk($id);
345 
346         if ($category->is_opt_bottom && !CityHelper::isOpt()) {
347             throw new CHttpException(404, 'Страница не найдена');
348         }
349 
350         $categoryUrl = Yii::app()->createUrl('/shop/category', ['id' => $id]);
351         $baseUrl = explode('?', $_SERVER['REQUEST_URI'])[0];
352         if ($baseUrl != $categoryUrl) {
353             throw new CHttpException(404, 'Страница не найдена');
354 //            $this->redirect($categoryUrl, true, 301);
355         }
356 
357         if ($category->is_noindex) {
358             $this->noindex = true;
359         }

Stack Trace

#9
+
 /home/p364072/public_html/index.php(111): CApplication->run()
106 HKontur::robots('robots/' . $languageCode . '/' . CITY_PREFIX . '.robots.txt');
107 HKontur::sitemap('sitemap/' . $languageCode . '/' . CITY_PREFIX . '.sitemap.xml');
108 
109 HKontur::checkRedirects();
110 
111 $app->run();
112 
113 if ($localMode || !empty($_GET['test'])) {
114    // echo microtime(true) - $start;
115 }
2024-03-29 21:54:39 LiteSpeed Yii Framework/1.1.18