Author Topic: Hide Pricing from Guests?  (Read 196 times)

geoffr

  • Beginner
  • *
  • Posts: 44
Hide Pricing from Guests?
« on: October 31, 2017, 08:12:16 am »
My client wishes to run their site as a Catalog only, unless the user is logged in, whereupon they will see the pricing.

Is this possible?  If so, how is it achieved?

Many thanks for your help.
Geoff

jenkinhill

  • UK Web Developer & Consultant
  • Global Moderator
  • Super Hero
  • *
  • Posts: 26358
  • Always on vacation
    • Jenkin Hill Internet
Re: Hide Pricing from Guests?
« Reply #1 on: October 31, 2017, 12:28:08 pm »
Kelvyn

Jenkin Hill Internet,
Keswick, Lake District

Unsolicited PMs/emails will be ignored.

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Currently using VM3.2.4 on Joomla 3.8.1 PHP 7.0.23

Testing VM3.2.5 on J!3.8.1

alexanderflr

  • Beginner
  • *
  • Posts: 38
  • VirtueMart Version: 3.2.2
Re: Hide Pricing from Guests?
« Reply #2 on: November 09, 2017, 15:27:46 pm »
I needed to have like that so I added in addtocart.php from /templates/youtemplatename/html/com_virtuemart/sublayouts
the following:

Code: [Select]
<?php 
$user
=JFactory::getUser();
if(
$user->id>0);
   else {
?>

<a class="notify btn btn-primary btn-block" href='http://linktologinorregister><?php echo vmText::('Login or Register to see prices'?></a><?php
return;
 } 
?>

VM 3.2.4 on Joomla! 3.8.1 Stable, PHP Version 7.0.25

geoffr

  • Beginner
  • *
  • Posts: 44
Re: Hide Pricing from Guests?
« Reply #3 on: November 10, 2017, 06:47:05 am »
So may I clarify:  In VirtueMart 1 (I am doing an upgrade), there was the Config option:

Price Configuration
Show Prices      
Membergroup to show prices to: (options):
"Registered"

Is this simple Config option no longer available? 

thanks,
Geoff

K&K media production

  • VirtueMart Developer Team
  • Global Moderator
  • Full Member
  • *
  • Posts: 834
  • VirtueMart Version: VM3 on J3
Re: Hide Pricing from Guests?
« Reply #4 on: November 12, 2017, 00:03:34 am »
configuration -> pricing -> Show Prices

and each shoppergroup has this config option: Enable shoppergroup specific price display