**in brif**

I am trying to hide or unpublished a module with another component.
Anybody know how to enable/disable a module for an specific menu item from code?

---

**Scenario:**

I am using the T3 to build my templates.

I use a component call Jreviews that list events and it is possible to customize views.
The component it is assigned by a joomla menu item.

I also asign a banner component to the top of the same menu item.

I only want the banner component the first time the page is load but not when the user search within the Jreviews component. (after the search joomla stay in the same url)

I can catch the search event within the Jreviews component and render a module by position.

```
<?php 
$position = 'user1';
$params     = array('style'=>'');
$document   = &JFactory::getDocument();
$renderer   = $document->loadRenderer('module');
$contents = '';
foreach (JModuleHelper::getModules($position) as $mod)  {   
    $contents .= $renderer->render($mod, $params);
}
echo $contents;
?>

```

but i get a duplicate with the one assigned in the component.
-------------------------------------------------------------

**Question**

how to show the module banner component ONLY when i load it by code with in the Jreview template?

Thanks a lot,

Eduardo