Author Topic: Menu-item specific modules and virtumart's redirects  (Read 1450 times)

posvitJason

  • Beginner
  • *
  • Posts: 3
Menu-item specific modules and virtumart's redirects
« on: December 20, 2011, 20:49:52 pm »
Alright, I'm muddling through the setup process for vm2, and I've encountered a small issue:

I've assigned Virtuemart Default Layout to a menu, then assigned the virtuemart modules to that menu item, so that they would only display on the virtuemart part of the site. However, the links to the cart, and any other redirect that Virtuemart preforms, no longer has the menu item in the URL, so the modules no longer show up.

Is there a way to fix this outside of modifying the code?

posvitJason

  • Beginner
  • *
  • Posts: 3
Re: Menu-item specific modules and virtumart's redirects
« Reply #1 on: December 28, 2011, 20:06:37 pm »
I don't like replying to myself, but I was sort of hoping for at least some acknowledgement.

Specifically, it seems to occur after adding a product to your cart, when you are given the option to either continue shopping or view your cart. Choosing either of these options takes you away from the menu item that the store is on.

PRO

  • Global Moderator
  • Super Hero
  • *
  • Posts: 10377
  • VirtueMart Version: 3+
Re: Menu-item specific modules and virtumart's redirects
« Reply #2 on: December 28, 2011, 21:19:21 pm »
You could create a module position ONLY for vmart


<?php if (JRequest::getVar('option')=='com_virtuemart') { ?>
<div id="positiondiv"><jdoc:include type="modules" name="vmart-position" /></div>
<?php } ?>

http://www.kaizenmediaworks.com/virtuemart-template-and-module-control
J3.9+ VM 3.4.2
Slowest Page Speed Score (88) (Category)
Fastest Page Speed Score (94-96) (productdetails)

posvitJason

  • Beginner
  • *
  • Posts: 3
Re: Menu-item specific modules and virtumart's redirects
« Reply #3 on: December 29, 2011, 15:07:02 pm »
Thank you. It doesn't solve the problem (my menu doesn't display the correct menu item), but it is a workaround.