News:

Support the VirtueMart project and become a member

Main Menu

Custom Text for shopper group

Started by fabioweb, July 05, 2018, 15:21:11 PM

Previous topic - Next topic

fabioweb

Hello, in my 3.2.14 virtuemart store i need to display some text only for shopper group "rivenditore"
In short i have two main shoppers group: "Cliente" and "Rivenditore"

Once a user is logged in and is "Rivenditore" i need to load some text somewhere into the website
if user is logged in and is "Cliente" the same text will not displayed

Is it possible?

Best regards

GJC Web Design

Get shopper Group

$userModel = VmModel::getModel('user');
$vmuser = $userModel->getCurrentUser();
$vmgroup = $vmuser->shopper_groups;

//$vmgroup is an array
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

Studio 42

If you manually set user shopper groups, you can use Joomla user groups restrictions to display a module an affiliate the users in "rivenditore" to this group.
This need one step more, but it's very more flexible after(you can add new menus for eg. Restricted acces to some pages ...)