Page 1 of 1

More Modular Sections - Footer

Posted: Wed Jun 15, 2022 8:19 am
by LeeFoster
With the recent work done by @heatherbell , @burt & others, along with the layout I'm looking to achieve for the footer of my site, I got to thinking can we make more sections of the site with PI modularity?

In this instance I'm thinking the footer but could it also be done for the header and other pages?

In terms of header and footer would we need to consider height and width in the modularity?

What are peoples thoughts?

Re: More Modular Sections - Footer

Posted: Wed Jun 15, 2022 9:50 am
by LeeFoster
So it is possible and quite simple to do. It's taken me about 1.5 hours to do using @heatherbell's modular contact us but I now have a PI modular footer.
modular pi.PNG

Re: More Modular Sections - Footer

Posted: Tue Sep 24, 2024 10:07 am
by LeeFoster
So I'm currently in the process of updating my footer to work on 1.0.8.20 and I'm having an issue with how MODULE_CONTENT_I_INSTALLED works. I've created a footer version of it, however, when I install a footer module it also updates to the configuration value with the contect of MODULE_CONTENT_I_INSTALLED as well.

Can anyone offer any advice?

Re: More Modular Sections - Footer

Posted: Tue Sep 24, 2024 1:14 pm
by burt
LeeFoster wrote: Tue Sep 24, 2024 10:07 am So I'm currently in the process of updating my footer to work on 1.0.8.20 and I'm having an issue with how MODULE_CONTENT_I_INSTALLED works. I've created a footer version of it, however, when I install a footer module it also updates to the configuration value with the contect of MODULE_CONTENT_I_INSTALLED as well.

Can anyone offer any advice?
So far as I recall, there are only three possibilities for Layout modules;
- index
- contact us
- product info

To add another would mean (I think, I haven't explored) a core code change in admin (one of the cgm files), a new layout module, and some child modules. Sounds like your new layout module uses MODULE_CONTENT_I_INSTALLED when it should use something like MODULE_CONTENT_FOOTER_INSTALLED

Hope this shines a light.

In return for my few minutes on this post, please take few minutes on this [ viewtopic.php?p=17822#p17822 ] and give us some feedback on the new look/features.

Re: More Modular Sections - Footer

Posted: Tue Sep 24, 2024 1:44 pm
by LeeFoster
burt wrote: Tue Sep 24, 2024 1:14 pm So far as I recall, there are only three possibilities for Layout modules;
- index
- contact us
- product info

To add another would mean (I think, I haven't explored) a core code change in admin (one of the cgm files), a new layout module, and some child modules. Sounds like your new layout module uses MODULE_CONTENT_I_INSTALLED when it should use something like MODULE_CONTENT_FOOTER_INSTALLED

Hope this shines a light.

In return for my few minutes on this post, please take few minutes on this [ viewtopic.php?p=17822#p17822 ] and give us some feedback on the new look/features.
I've already added footer as a Layout module -

Code: Select all

const GROUP_KEYS = [
      'contact_us' => 'MODULE_CONTENT_CU_INSTALLED',
      'index' => 'MODULE_CONTENT_I_INSTALLED',
      'product_info' => 'MODULE_CONTENT_PI_INSTALLED',
      'footer' => 'MODULE_CONTENT_FOOTER_INSTALLED',
    ];
    
Created the module cm_footer_modular.php and replaced MODULE_CONTENT_I_INSTALLED with MODULE_CONTENT_FOOTER_INSTALLED as well as creating some child modules. I've double checked for any stray instances of MODULE_CONTENT_PI_INSTALLED