I'm new to prestashop and was wondering how I would go about creating a landing page for my store. I can't seem to fully wrap my mind around .tpl
and hooks
. Any pointers would be helpful.
Thanks in advance!
I'm new to prestashop and was wondering how I would go about creating a landing page for my store. I can't seem to fully wrap my mind around .tpl
and hooks
. Any pointers would be helpful.
Thanks in advance!
It is easy using prestashop built in modules. Normally prestashop shows a slider, featured products, and some text (may show or not) on home page.
If you want to display only some text, some images or a welcome page (like you said landing page), then you have to uninstall all the modules at admin and only keep the " Home text editor " module. This module provides an editor where you can insert any sort of contents like images, videos, flash contents etc etc. Place your content and save it and all those contents will be displayed on home page.
Normally PS provides a 3 columns page layout and for landing pages normally a single column layout is used, which means, the left and right columns may be not needed. So there is another solution for it. You can remove the left and right columns from home page by making some tpl changes. Can be done as followed:
*Left Column : * Open header.tpl file in your theme and find the following line
<!-- Left -->
<div id="left_column" class="column grid_2 alpha">
{$HOOK_LEFT_COLUMN}
</div>
and replace it with
{if $page_name=='index'}
<!-- Left -->
<div id="left_column" class="column grid_2 alpha">
{$HOOK_LEFT_COLUMN}
</div>
{/if}
*Right Column : * Open footer.tpl in your theme and find the following code
<!-- Right-->
<div id="right_column" class="column grid_2 alpha">
{$HOOK_RIGHT_COLUMN}
</div>
and replace it with
{if $page_name=='index'}
<!-- Right-->
<div id="right_column" class="column grid_2 alpha">
{$HOOK_RIGHT_COLUMN}
</div>
{/if}
This will not display the left and right columns on home page or index page. There may be some need to adjust the center column width which you may be able to do easily.
Hope this will help.
Thank you