Back to Opencart

File extension\opencart\catalog\controller\module\information.php

docs/api/source-extension.opencart.catalog.controller.module.information.html

4.1.0.36.3 KB
Original Source

Namespaces

Classes

| 1: | <?php | | 2: | namespace Opencart\Catalog\Controller\Extension\Opencart\Module; | | 3: | /** | | 4: | * Class Information | | 5: | * | | 6: | * @package Opencart\Catalog\Controller\Extension\Opencart\Module | | 7: | */ | | 8: | class Information extends \Opencart\System\Engine\Controller { | | 9: | /** | | 10: | * Index | | 11: | * | | 12: | * @return string | | 13: | */ | | 14: | public function index(): string { | | 15: | $this->load->language('extension/opencart/module/information'); | | 16: | | | 17: | $this->load->model('catalog/information'); | | 18: | | | 19: | $data['informations'] = []; | | 20: | | | 21: | foreach ($this->model_catalog_information->getInformations() as $result) { | | 22: | $data['informations'][] = [ | | 23: | 'title' => $result['title'], | | 24: | 'href' => $this->url->link('information/information', 'language=' . $this->config->get('config_language') . '&information_id=' . $result['information_id']) | | 25: | ]; | | 26: | } | | 27: | | | 28: | $data['contact'] = $this->url->link('information/contact', 'language=' . $this->config->get('config_language')); | | 29: | $data['sitemap'] = $this->url->link('information/sitemap', 'language=' . $this->config->get('config_language')); | | 30: | | | 31: | return $this->load->view('extension/opencart/module/information', $data); | | 32: | } | | 33: | } | | 34: | |

OpenCart API API documentation generated by ApiGen dev-master