delete subscriptions form from before footer
Hi guys
Can anyone tell me please why this code doesn't do anything (5.4.1)? I am simply trying to remove the big newsletter subscription box from above the footer. I have a customskin created, and I am using main.php, which already has a function for moveTemplatesInLists with some add and delete functions that do work. But this one doesn't do anything. 'modules/XC/NewsletterSubscriptions/form/subscribe.twig' => [ static::TO_DELETE => [ ['layout.main.footer.before', \XLite\Model\ViewList::INTERFACE_CUSTOMER], ], ], |
Re: delete subscriptions form from before footer
Simply find the needed template via Template editor and delete the responsible code. Otherwise - apply the "display: none;" style to this block.
To be honest, I'm not sure you are using the best way just to get rid of the specific section. |
Re: delete subscriptions form from before footer
My understanding was it was best to stop the code from running in the first place.
What I really want to do though is move the subscription from before the footer, to within the footer. If I copy and paste the template in to the footer, it gives a fatal error. I have even tried to have the equivalent "TO_ADD" code in my main.php file. |
Re: delete subscriptions form from before footer
Since you want to move the place of the template, you can override the viewer class
The code responsible of outputting the template where it is, is Code:
/** classes/XLite/Module/XC/NewsletterSubscriptions/View/SubscribeBlock.php Now, I am a bit confused on how to override. The code above precedes the line Code:
class SubscribeBlock extends \XLite\View\AView classes/XLite/Module/XC/NewsletterSubscriptions/View/SubscribeBlock.php If nothing else works, you can always edit by hand the line Code:
|
Re: delete subscriptions form from before footer
Since the list is defined in the class you have to use moveClassesInLists not moveTemplatesInLists
|
All times are GMT -8. The time now is 03:07 AM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.