Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.
- Index
- » Chameleon / ChameleonLite
- » Chameleon
- » A specific template for VirtueMart...
A specific template for VirtueMart Shoppers
Re: A specific template for VirtueMart Shoppers
Hi francesco.r,
You're right, there's nothing on the form about the shopper group. I made some tough decisions about which things I would put on there (since there are over 50 things that I could put), and the shopper group was not on the list. I'll take this as a vote to add it though!
However it's easy to use the PHP box to do this. To write this rule I am looking on the JomGenius page for Virtuemart: http://www.metamodpro.com/jomgenius/par … andcheckvm
$vm = JomGenius("virtuemart"); // always put this line first
if ( $vm->check("shopper_group = 5") ) return true;
That will make the rule SUCCEED if the logged in user is in shopper group 5.
If you want to check for more than one group:
$vm = JomGenius("virtuemart"); // always put this line first
if ( $vm->check("shopper_group = 5, 7, 11") ) return true;
That will make the rule SUCCEED if the user is in groups 5, 7 or 11.
Note: this rule needs to go in the PHP box in the left column, NOT the PHP box in the SUCCEED or FAIL rules.
Hope that helps,
Stephen
- Index
- » Chameleon / ChameleonLite
- » Chameleon
- » A specific template for VirtueMart...
Board Info
- Board Stats:
- Total Topics:
- 1689
- Total Polls:
- 6
- Total Posts:
- 5942
- Total Posts Today:
- 1
- User Info:
- Total Users:
- 7623
- Newest User:
- laptopreviews21
- Members Online:
- 0
- Guests Online:
- 117
- 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