I work on a module designed to show contents both on mobile and regular theme with different layouts.
First, I created a mobile subfolder in the module folder.
Second, I created a smarty template for the mobile contents in the mobile subfolder mobile/mysmarty.tpl.
Third, I added this test in the mysmarty.tpl situated in the module folder :
{if $mobile_device} {include file='./mobile/mysmarty.tpl' inline} {else} ... {/if}
I have issues while activating the smarty caching feature in prestashop : the regular web contents is shown on the mobile template. Without cache activated, everything works well.
I tried without inline directive, it's the same.
Are there best practices to design these kind of modules? Some known examples?
Thanks,