From 50775039d150527494a0e56553b1e01e0471f82b Mon Sep 17 00:00:00 2001 From: Dima Fedorchuk Date: Thu, 7 Jul 2016 12:29:04 +0300 Subject: [PATCH] Seo naznach h1 --- frontend/widgets/Seo.php | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/frontend/widgets/Seo.php b/frontend/widgets/Seo.php index fd6f621..b940226 100755 --- a/frontend/widgets/Seo.php +++ b/frontend/widgets/Seo.php @@ -94,13 +94,17 @@ class Seo extends Widget - if (isset($filter['brands']) && count($filter['brands']) == 1) { + if (isset($filter['brands']) && count($filter['brands']) == 1 ) { $model = Brand::find()->where(['alias' => $filter['brands'][0]])->one(); - return $this->selectSeoData(self::H1).' '.$model->name; + if($this->selectSeoData(self::H1) == $this->category_name) { + return $this->selectSeoData(self::H1) . ' ' . $model->name; + }else { + return $this->selectSeoData(self::H1); + } - } if (isset($filter['options']["naznacenie"]) && count($filter['options']["naznacenie"]) == 1) { + } else if (isset($filter['options']["naznacenie"]) && count($filter['options']["naznacenie"]) == 1) { $model = TaxOption::find()->where(['alias' => $filter['options']["naznacenie"]])->one(); return $this->selectSeoData(self::H1).' '.$model->value->value; -- libgit2 0.21.4