News:

Support the VirtueMart project and become a member

Main Menu

Show module ONLY on homepage of VM2

Started by nflmerch, December 13, 2011, 23:35:57 PM

Previous topic - Next topic

balai


lipes

#16
humm.... tks Balay :)

But if think it could be more easy and nice in trying to discover the code to do something like:

<?php if
(!( $mod_articles_category  == 'hide'
and JRequest::getVar('view')=='category' or JRequest::getVar('view')=='productdetails' or JRequest::getVar('view')=='categories'): { ?>

or
$com_virtuemart == 'view' and JRequest::getVar('hide') == 'com_content'  ? lol .. 8)


maybe this could be related with com_content too...  I'm yet dont know the diference between categories and category .. lol its only a singular and plural word?!  ::)

i dont know the right code to apply in bold zone.. so i'm trying to discover in google too...
VM V. online: J2.5.14 | VM 2.0.20a | SQL 5.1.70 | PHP 5.3.25

PRO

lipes, U need to wrap it in a J;;request to check for the component = virtuemart

<?php if (JRequest::getVar('option') == 'com_virtuemart') {

Then execute more ifs

}

OR: 

&&  (JRequest::getVar('option') == 'com_virtuemart')

lipes

Grade A++ to Tampa Bay hero member :P

<?php if (JRequest::getVar('option') == 'com_virtuemart') {?> <?php if (JRequest::getVar('view')=='category' or JRequest::getVar('view')=='productdetails' or JRequest::getVar('view')=='categories') { ?>
<div class="lateral"><jdoc:include type="modules" name="lateral" /></div><?php ?>
<?php ?>

begin to understand a little of php @ joomla .. (I think  ::) ) .. lol :) it's solved.. uff!
Thanks one more time BanquetTables.pro aka Kaizen Media Works !!

Now the next step is to try to understand what is happening with the VM2 Manufacturer Module (Backend) in vm2 (front end) ..
VM V. online: J2.5.14 | VM 2.0.20a | SQL 5.1.70 | PHP 5.3.25

resorter

Quote from: BanquetTables.pro on January 06, 2012, 14:06:34 PM
Quote from: tobisagt on January 06, 2012, 00:37:05 AM

So, the itemid is the solution. It would be nice if someone tell me how to fix it?  :-\

Thx.
Tobi

this code

<?php if (JRequest::getVar('view')=='category') { ?>
<jdoc:include type="modules" name="module" />
<?php } ?>

will show the module anytime this  &view=category

is in the url. with or without the itemid.



Hi, this is very useful and where exactly have to paste this code?
Thanks

lipes

VM V. online: J2.5.14 | VM 2.0.20a | SQL 5.1.70 | PHP 5.3.25

resorter