VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: raunhar on December 14, 2017, 07:20:43 AM

Title: How not to assign module from product detail pages.
Post by: raunhar on December 14, 2017, 07:20:43 AM
Joomla 3.8.3
VM 3.4

I am using Custom Filter by Break designs. I want to display the Filter module only on the Category pages, not on the product detail page.

I have installed Advance Module Manager (free version).

Please suggest a way, so that the Filter module does not show on the product detail pages.

There are around 300 products.
Title: Re: How not to assign module from product detail pages.
Post by: Studio 42 on December 14, 2017, 13:36:32 PM
You need to check the view="productDetails" with PHP  in your template
Title: Re: How not to assign module from product detail pages.
Post by: raunhar on December 14, 2017, 13:50:44 PM
Quote from: Studio 42 on December 14, 2017, 13:36:32 PM
You need to check the view="productDetails" with PHP  in your template
Please explain in layman language.

Sent from my Moto G (4) using Tapatalk

Title: Re: How not to assign module from product detail pages.
Post by: raunhar on December 14, 2017, 13:51:33 PM
I am using template by enginetemplates

Sent from my Moto G (4) using Tapatalk

Title: Re: How not to assign module from product detail pages.
Post by: Jörgen on December 14, 2017, 14:19:20 PM
The Advanced Module Manager has some code examples that describe how to look for views like "productdetails".
You must hide the module manager when it is displayed in the view "productdetails". Please look for more detail a Regular labs.

regards

Jörgen @ Kreativ Fotografi
Title: Re: How not to assign module from product detail pages.
Post by: raunhar on December 14, 2017, 14:28:48 PM
It is free version, and there is no support for free version

Sent from my Moto G (4) using Tapatalk

Title: Re: How not to assign module from product detail pages.
Post by: Jörgen on December 14, 2017, 15:07:55 PM
You need pro version.

regards

Jörgen @ Kreativ Fotografi
Title: Re: How not to assign module from product detail pages.
Post by: Studio 42 on December 14, 2017, 15:39:44 PM
The standard way to check for a view is
<?php $inputJFactory::getApplication()->input;
$view $input->get('view');
if(
$view !== 'productdetails') { ?>

<jdoc:include type="modules" name="position-3" style="xhtml" />
<?php  ?>