How do I do this on a new product list created in a block? I have tried:
hide_toolbar="1" in the block parameters
Also
<referenceContainer name="product_list_toolbar" display="false" /> in the layout XML update
Magento 2.1.13
Ultimo theme
Hi ken,
You can remove toolbar by commenting in list.phtml the 2 lines with
<?php echo $block->getToolbarHtml() ?>
To hide it only in category page than wrap getToolbarHtml() with an if statement.
<?php if (!$this->getMyHideFlag()): ?> <?php echo $block->getToolbarHtml() ?> <?php endif; ?>
In custom module's layout/catalog_category_view.xml add 'my_hide_flag' argument (or use layout instruction <action>). Set this 'my_hide_flag' to 1. Reference the block 'category.products.list'.
if issue solved,Click Kudos & Accept as Solution
Just try to add to Layout Update XML this (use display="false" param instead of remove="true"):
<referenceBlock name="product_list_toolbar" display="false" />
then clean cache and toolbar should disappear.