Welcome to the MetaMod and Chameleon Support Forums.

Before posting, please check out the FAQs.

helpme

 

Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.

 

Little help

Little help

Hello,

I First of all thanks for this great module but i can't get it worked.I want to show some modules in some virtuemart categories but no luck.

I tried this codes.

Code:

$vm = JomGenius("virtuemart");

if ($vm->check("category_ids = 1, 2, 6")) return 105;

Code:

if ($option == "com_virtuemart") {

$category_id = JRequest::getVar("category_id");
$category = JRequest::getVar("category", null);
$page = JRequest::getVar("page");
if ($page == "shop.browse") {

  /* when browsing a specific category on browse page (e.g. category 2) */
  if ($category_id == "1") return 105; /* module 101 for category 2 */
  if ($category_id == "2") return 105; /* module 102 for category 3 */
  if ($category_id == "6") return 105; /* module 103 for category 4 */

  }
}

I set all the required options like postiot, published but cant see anything.

I'm using jm2.5, vm 2.02 and latest metamod. Because i'm using vm2 so this is the problem?

Little help will be appreciated.

Thanks.

www.downloadhutz.com

Desmond
Beginner Modder
ranks
useravatar
Offline
1 Posts
Administrator has disabled public posting

Re: Little help

Hi Desmond,

VirtueMart 2.0 is supported only on the Joomla 2.5 version of MetaMod, so your versions are ok.

Not all of the JomGenius documentation for VM2.0 is up to date on this site yet, but the category_id and category_ids keywords are supposed to work the same as before.

Can I suggest that you just try category_id instead of category_ids, and see if that works any better? The difference between the two is that category_id gives the id of the immediate category that a product is in, while category_ids gives the ids of ALL categories that the product is in, if it's in more than one.

Please try that and tell me if it works any better.

i.e.

$vm = JomGenius("virtuemart");
if ($vm->check("category_id = 1, 2, 6")) return 105;


Also, please ensure that you have everything else set up right - read through the Quick Start guide on this site.

Cheers,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3329 Posts
User info in posts
Administrator has disabled public posting

Board Info

Board Stats:
 
Total Topics:
1689
Total Polls:
6
Total Posts:
5941
Posts this week:
1
User Info:
 
Total Users:
5361
Newest User:
scotti64d
Members Online:
0
Guests Online:
155

Online: 
There are no members online

Forum Legend:

 Topic
 New
 Locked
 Sticky
 Active
 New/Active
 New/Locked
 New Sticky
 Locked/Active
 Active/Sticky
 Sticky/Locked
 Sticky/Active/Locked