{"id":4601,"date":"2013-04-24T15:42:55","date_gmt":"2013-04-24T12:42:55","guid":{"rendered":"http:\/\/blog.belvg.com\/?p=4601"},"modified":"2019-09-27T15:49:31","modified_gmt":"2019-09-27T13:49:31","slug":"homepage-in-prestashop","status":"publish","type":"post","link":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html","title":{"rendered":"Homepage in Prestashop"},"content":{"rendered":"\n<p><strong>Controller (IndexController)<\/strong><\/p>\n<p style=\"text-align: left;\" align=\"center\">\/controllers\/front\/IndexController.php<\/p>\n<p>IndexC&#1086;ntr&#1086;ller&nbsp; is a controller that is responsible for generating a homepage. Like most controllers used in the front end, it is inherited from the Fr&#1086;ntC&#1086;ntr&#1086;ller class, delivering only the method initC&#1086;ntent.<!--more--><\/p>\n<pre class=\"lang:php decode:true\">public function initContent()\r\n                {\r\n                               parent::initContent();\r\n                               $this-&gt;context-&gt;smarty-&gt;assign('HOOK_HOME', Hook::exec('displayHome'));\r\n                               $this-&gt;setTemplate(_PS_THEME_DIR_.'index.tpl');\r\n                }<\/pre>\n<p>It is exactly in this method where the hook displ&#1072;yH&#1086;me is called and the template that is responsible for the content output is defined.<\/p>\n<p>This controller is remarkable in the way that it does not use models, i.e. it does not have data that should be retrieved from the database. All of the data that are used on the homepage are taken from the modules&rsquo; tables.<\/p>\n<p>&nbsp;<\/p>\n<p align=\"center\"><strong>Template (index.tpl)<\/strong><\/p>\n<p>\/themes\/you_theme\/index.tpl<\/p>\n<p>The content of the template is very simple. All that it contains is the content output of the hook displ&#1072;yH&#1086;me:<\/p>\n<p>{$HOOK_HOME}<\/p>\n<p>&nbsp;<\/p>\n<p align=\"center\"><strong>Standard modules<\/strong><\/p>\n<p>There are only 3 standard modules that are using the hook displ&#1072;yH&#1086;me:<\/p>\n<ul>\n<li>Editorial<\/li>\n<li>Homefeatured<\/li>\n<li>Homeslider<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<p><strong>Editorial<br>\n<\/strong><\/p>\n<ul>\n<li>This module outputs the formatted content on the homepage. It uses the Edit&#1086;ri&#1072;lCl&#1072;ss class.<\/li>\n<li>The tables that store the module data: editorial and editorial_lang.<\/li>\n<li>The template that outputs the content: modules\/editorial\/editorial.tpl<\/li>\n<li>CSS styles: modules\/editorial \/editorial.css<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<p><strong>Homefeatured<\/strong><\/p>\n<ul>\n<li>Allows displaying the goods that fall under the Home category on the homepage.<\/li>\n<li>The data that the module receives from the function Category::getProducts.<\/li>\n<li>The template that outputs the content: modules\/homefeatured\/ homefeatured.tpl<\/li>\n<li>CSS styles: modules\/homefeatured\/homefeatured.css<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<p><strong>HomeSlider<\/strong><\/p>\n<ul>\n<li>Allows displaying slider on the homepage.<\/li>\n<li>The data that the module stores in the tables homeslider, homeslider_slides, homeslider_slides_lang.<\/li>\n<li>The template that outputs the content: modules\/homeslider\/homeslider.tpl<\/li>\n<li>CSS styles: modules\/homeslider\/bx_styles.css<\/li>\n<li>Js files used by the module: modules\/homeslider\/js\/jquery.bxSlider.min.js, modules\/homeslider\/js\/homeslider.js<\/li>\n<\/ul>\n<div class=\"module_in_content_container\"><a href=\"https:\/\/belvg.com\/prestashop-development\" class=\"link_to_module\" target=\"_blank\" rel=\"noopener\"><\/a><div class=\"module_content\"><img src=\"https:\/\/belvg.com\/blog\/wp-content\/uploads\/2019\/06\/development_prestashop.png\" width=\"100\" height=\"100\" alt=\"development_prestashop\" class=\"module_image\" title=\"Homepage in Prestashop\"><div class=\"module_content_part\"><h3 class=\"title\">PrestaShop Development<\/h3><p class=\"module_content_text\">Take your online store to the next level with BelVG PrestaShop Development <\/p><a href=\"https:\/\/belvg.com\/prestashop-development\" class=\"link_2_to_module\" target=\"_blank\" style=\"display:inline-block\" rel=\"noopener\"><span class=\"read-more\">Visit the page<\/span><\/a><\/div><\/div><\/div>\n\n","protected":false},"excerpt":{"rendered":"Controller (IndexController) \/controllers\/front\/IndexController.php IndexC&#1086;ntr&#1086;ller&#160; is a controller that is responsible for generating a homepage. Like &#8230;","protected":false},"author":12,"featured_media":8748,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"image","meta":{"_acf_changed":false,"footnotes":""},"categories":[15,300],"tags":[445,69],"class_list":["post-4601","post","type-post","status-publish","format-image","has-post-thumbnail","hentry","category-prestashop","category-prestashop-guide","tag-prestashop","tag-tips","post_format-post-format-image"],"acf":[],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.4 - aioseo.com -->\n\t<meta name=\"description\" content=\"The article describes main controller, template file and standard modules responsible for generating a homepage in Prestashop.\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Aliaksandr Simonchik\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html\" \/>\n\t\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.4\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#article\",\"name\":\"Homepage in Prestashop | BelVG Blog\",\"headline\":\"Homepage in Prestashop\",\"author\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/author\\\/alex-simonchik#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#organization\"},\"image\":{\"@type\":\"ImageObject\",\"url\":\"https:\\\/\\\/belvg.com\\\/blog\\\/wp-content\\\/uploads\\\/2013\\\/04\\\/presta-41.jpg\",\"width\":682,\"height\":170},\"datePublished\":\"2013-04-24T15:42:55+02:00\",\"dateModified\":\"2019-09-27T15:49:31+02:00\",\"inLanguage\":\"en-US\",\"commentCount\":4,\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#webpage\"},\"articleSection\":\"Prestashop, Prestashop Guide, Prestashop, Tips, Image\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/belvg.com\\\/blog\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/prestashop#listItem\",\"name\":\"Prestashop\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/prestashop#listItem\",\"position\":2,\"name\":\"Prestashop\",\"item\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/prestashop\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/prestashop\\\/prestashop-guide#listItem\",\"name\":\"Prestashop Guide\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/prestashop\\\/prestashop-guide#listItem\",\"position\":3,\"name\":\"Prestashop Guide\",\"item\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/prestashop\\\/prestashop-guide\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#listItem\",\"name\":\"Homepage in Prestashop\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/prestashop#listItem\",\"name\":\"Prestashop\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#listItem\",\"position\":4,\"name\":\"Homepage in Prestashop\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/prestashop\\\/prestashop-guide#listItem\",\"name\":\"Prestashop Guide\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#organization\",\"name\":\"BelVG Blog\",\"description\":\"Magento and Prestashop articles\",\"url\":\"https:\\\/\\\/belvg.com\\\/blog\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/author\\\/alex-simonchik#author\",\"url\":\"https:\\\/\\\/belvg.com\\\/blog\\\/author\\\/alex-simonchik\",\"name\":\"Aliaksandr Simonchik\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#authorImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/6553917a81b1da7866b8b875368df6cbbec56413c3438694df8539de7fb092c0?s=96&d=mm&r=g\",\"width\":96,\"height\":96,\"caption\":\"Aliaksandr Simonchik\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#webpage\",\"url\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html\",\"name\":\"Homepage in Prestashop | BelVG Blog\",\"description\":\"The article describes main controller, template file and standard modules responsible for generating a homepage in Prestashop.\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/author\\\/alex-simonchik#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/author\\\/alex-simonchik#author\"},\"image\":{\"@type\":\"ImageObject\",\"url\":\"https:\\\/\\\/belvg.com\\\/blog\\\/wp-content\\\/uploads\\\/2013\\\/04\\\/presta-41.jpg\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html\\\/#mainImage\",\"width\":682,\"height\":170},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/homepage-in-prestashop.html#mainImage\"},\"datePublished\":\"2013-04-24T15:42:55+02:00\",\"dateModified\":\"2019-09-27T15:49:31+02:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/belvg.com\\\/blog\\\/\",\"name\":\"BelVG Blog\",\"description\":\"Magento and Prestashop articles\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Homepage in Prestashop | BelVG Blog","description":"The article describes main controller, template file and standard modules responsible for generating a homepage in Prestashop.","canonical_url":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#article","name":"Homepage in Prestashop | BelVG Blog","headline":"Homepage in Prestashop","author":{"@id":"https:\/\/belvg.com\/blog\/author\/alex-simonchik#author"},"publisher":{"@id":"https:\/\/belvg.com\/blog\/#organization"},"image":{"@type":"ImageObject","url":"https:\/\/belvg.com\/blog\/wp-content\/uploads\/2013\/04\/presta-41.jpg","width":682,"height":170},"datePublished":"2013-04-24T15:42:55+02:00","dateModified":"2019-09-27T15:49:31+02:00","inLanguage":"en-US","commentCount":4,"mainEntityOfPage":{"@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#webpage"},"isPartOf":{"@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#webpage"},"articleSection":"Prestashop, Prestashop Guide, Prestashop, Tips, Image"},{"@type":"BreadcrumbList","@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/#listItem","position":1,"name":"Home","item":"https:\/\/belvg.com\/blog\/","nextItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/category\/prestashop#listItem","name":"Prestashop"}},{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/category\/prestashop#listItem","position":2,"name":"Prestashop","item":"https:\/\/belvg.com\/blog\/category\/prestashop","nextItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/category\/prestashop\/prestashop-guide#listItem","name":"Prestashop Guide"},"previousItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/category\/prestashop\/prestashop-guide#listItem","position":3,"name":"Prestashop Guide","item":"https:\/\/belvg.com\/blog\/category\/prestashop\/prestashop-guide","nextItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#listItem","name":"Homepage in Prestashop"},"previousItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/category\/prestashop#listItem","name":"Prestashop"}},{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#listItem","position":4,"name":"Homepage in Prestashop","previousItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/category\/prestashop\/prestashop-guide#listItem","name":"Prestashop Guide"}}]},{"@type":"Organization","@id":"https:\/\/belvg.com\/blog\/#organization","name":"BelVG Blog","description":"Magento and Prestashop articles","url":"https:\/\/belvg.com\/blog\/"},{"@type":"Person","@id":"https:\/\/belvg.com\/blog\/author\/alex-simonchik#author","url":"https:\/\/belvg.com\/blog\/author\/alex-simonchik","name":"Aliaksandr Simonchik","image":{"@type":"ImageObject","@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#authorImage","url":"https:\/\/secure.gravatar.com\/avatar\/6553917a81b1da7866b8b875368df6cbbec56413c3438694df8539de7fb092c0?s=96&d=mm&r=g","width":96,"height":96,"caption":"Aliaksandr Simonchik"}},{"@type":"WebPage","@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#webpage","url":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html","name":"Homepage in Prestashop | BelVG Blog","description":"The article describes main controller, template file and standard modules responsible for generating a homepage in Prestashop.","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/belvg.com\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#breadcrumblist"},"author":{"@id":"https:\/\/belvg.com\/blog\/author\/alex-simonchik#author"},"creator":{"@id":"https:\/\/belvg.com\/blog\/author\/alex-simonchik#author"},"image":{"@type":"ImageObject","url":"https:\/\/belvg.com\/blog\/wp-content\/uploads\/2013\/04\/presta-41.jpg","@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html\/#mainImage","width":682,"height":170},"primaryImageOfPage":{"@id":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html#mainImage"},"datePublished":"2013-04-24T15:42:55+02:00","dateModified":"2019-09-27T15:49:31+02:00"},{"@type":"WebSite","@id":"https:\/\/belvg.com\/blog\/#website","url":"https:\/\/belvg.com\/blog\/","name":"BelVG Blog","description":"Magento and Prestashop articles","inLanguage":"en-US","publisher":{"@id":"https:\/\/belvg.com\/blog\/#organization"}}]}},"aioseo_meta_data":{"post_id":"4601","title":"Homepage in Prestashop | #site_title","description":"The article describes main controller, template file and standard modules responsible for generating a homepage in Prestashop.","keywords":[{"label":"Homepage in Prestashop","value":"Homepage in Prestashop"}],"keyphrases":null,"focus_keyword":null,"additional_keywords":null,"truseo_locale":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_custom_url":null,"og_image_custom_fields":null,"og_image_url":null,"og_image_width":null,"og_image_height":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_image_url":null,"twitter_title":null,"twitter_description":null,"schema_type":"default","schema_type_options":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[]},"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"limit_modified_date":false,"ai":null,"breadcrumb_settings":null,"seo_analyzer_scan_date":null,"created":"2026-11-03 18:38:13","updated":"2026-11-03 18:38:13"},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/belvg.com\/blog\/\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">\u00bb<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/belvg.com\/blog\/category\/prestashop\" title=\"Prestashop\">Prestashop<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">\u00bb<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/belvg.com\/blog\/category\/prestashop\/prestashop-guide\" title=\"Prestashop Guide\">Prestashop Guide<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">\u00bb<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tHomepage in Prestashop\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/belvg.com\/blog\/"},{"label":"Prestashop","link":"https:\/\/belvg.com\/blog\/category\/prestashop"},{"label":"Prestashop Guide","link":"https:\/\/belvg.com\/blog\/category\/prestashop\/prestashop-guide"},{"label":"Homepage in Prestashop","link":"https:\/\/belvg.com\/blog\/homepage-in-prestashop.html"}],"post_mailing_queue_ids":[],"_links":{"self":[{"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/posts\/4601","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/users\/12"}],"replies":[{"embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/comments?post=4601"}],"version-history":[{"count":7,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/posts\/4601\/revisions"}],"predecessor-version":[{"id":24087,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/posts\/4601\/revisions\/24087"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/media\/8748"}],"wp:attachment":[{"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/media?parent=4601"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/categories?post=4601"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/tags?post=4601"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}