Jump to content

Bypass PHP code 'if'


apollowebdes

Recommended Posts

Hi All,

 

I basically know very little about PHP and need some help.

 

I am working on a joomla template with virtuemart.

 

What i would like to do is have a module position not show on a particular virtuemart page.

 

What i have so far only turns of the modules for that page off, not the whole module position.

 

I need to know the PHP code to stop a section of code(RIGHT COLUMN) showing if it == the virtuemart page.

 

This is what i tried. My basic code in yellow.

        <?php if(@$GLOBALS['page'] != "shop.product_details"){ ?> 

  <?php if ( $ammd_left || $ammd_right ) { ?>

<!-- RIGHT COLUMN -->

  <div id="ammd-colwrap">

  <div class="ammd-innerpad">

  <?php if ($hasSubnav) : ?>

<div id="ammd-subnav" class="moduletable_menu">

<h3 class="clearfix"><span class="right-bg clearfix"><span class="left-bg">On this page</span></span></h3>

<div class="ammd-boxct-wrap"><div class="ammd-box-ct">

  <?php if ($ammdmenu) $ammdmenu->genMenu (1,1); ?>

</div></div>

</div>

<?php endif; ?>

  <jdoc:include type="modules" name="left" style="ammdmodule" />

                <jdoc:include type="modules" name="right" style="ammdmodule" />

  </div></div>

        <?php } ?>

  <!-- //RIGHT COLUMN -->

  <?php } ?>

 

So if anyone can help me to stop this section of code(RIGHT COLUMN), loading on the shop.product_details page that would be fantastic.

 

Thanks in advance.

 

Matt

Link to comment
https://forums.phpfreaks.com/topic/165759-bypass-php-code-if/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.