Can anyone help me, how to add a custom section for category products section using custom module in magento2.
Please find the screenshot below.
Stack Exchange network consists of 181 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.Visit Stack Exchange
Magento Stack Exchange is a question and answer site for users of the Magento e-Commerce platform. It only takes a minute to sign up.Sign up to join this community
Please try with the below code which will help you how to add custom section to the category landing page from your custom module.
<?xml version="1.0"?> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd"> <body> <referenceContainer name="category.product.addto"> <block class="Magento\Framework\View\Element\Template" name="magently.ajax.info2" template="Magently_Ajax::test.phtml" /> </referenceContainer> </body> </page>
<?php echo "Custom Template" ?>
Please note:- may be the above code will not give exact result...change the reference container name and try it from your end.
class="Magento\Framework\View\Element\Template" based on your requirement you can change the block class.