Commit 50775039d150527494a0e56553b1e01e0471f82b
1 parent
8afa1bf2
Seo naznach h1
Showing
1 changed file
with
7 additions
and
3 deletions
Show diff stats
frontend/widgets/Seo.php
... | ... | @@ -94,13 +94,17 @@ class Seo extends Widget |
94 | 94 | |
95 | 95 | |
96 | 96 | |
97 | - if (isset($filter['brands']) && count($filter['brands']) == 1) { | |
97 | + if (isset($filter['brands']) && count($filter['brands']) == 1 ) { | |
98 | 98 | $model = Brand::find()->where(['alias' => $filter['brands'][0]])->one(); |
99 | - return $this->selectSeoData(self::H1).' '.$model->name; | |
100 | 99 | |
100 | + if($this->selectSeoData(self::H1) == $this->category_name) { | |
101 | + return $this->selectSeoData(self::H1) . ' ' . $model->name; | |
102 | + }else { | |
103 | + return $this->selectSeoData(self::H1); | |
104 | + } | |
101 | 105 | |
102 | 106 | |
103 | - } if (isset($filter['options']["naznacenie"]) && count($filter['options']["naznacenie"]) == 1) { | |
107 | + } else if (isset($filter['options']["naznacenie"]) && count($filter['options']["naznacenie"]) == 1) { | |
104 | 108 | |
105 | 109 | $model = TaxOption::find()->where(['alias' => $filter['options']["naznacenie"]])->one(); |
106 | 110 | return $this->selectSeoData(self::H1).' '.$model->value->value; | ... | ... |