I deduce a site map of html , that is, a category, and under each category the goods from this category. The question is, like when displaying a link to a product, insert a мета-description of the product in the title link So I bring the goods. Thank you in advance!

 $this->data['products'] = array(); $product_total = $this->model_catalog_product->getTotalProducts($data); $results = $this->model_catalog_product->getProducts($data); foreach ($results as $result) { $this->data['products'][] = array( 'product_id' => $result['product_id'], 'name' => $result['name'], 'href' => $this->url->link('product/product', 'path=' . $this->request->get['path'] . '&product_id=' . $result['product_id']) ); } 

    1 answer 1

    Think so:

     $title = $this->document->getTitle().' '.$this->document->getDescription(); $this->document->setTitle($title);