News:

Looking for documentation? Take a look on our wiki

Main Menu

[VM3] Hide add to cart option to unregistered?

Started by Alexanderz, March 03, 2016, 10:30:15 AM

Previous topic - Next topic

Alexanderz

Could you give me a tip on how to do?
It is very important for me to implement this thing.

I need to create a php file and enter the code for the dump or do I add in addtocartbar.php?

The help you are giving me all of you is still appreciated.

GJC Web Design

after $user = JFactory::getUser();

add

print 'Debug Line '.__LINE__.' $user <pre>'; print_r ($user); print "</pre><br />\n";
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

Alexanderz

#17
adding, seems not to appear none debug message. When I enter inside the object, however, comes out the error message:

"Fatal error: Call to a member function get () on a non-object in /templates/mytemplates/html/com_virtuemart/sublayouts/addtocartbar.php on line 28"

GJC Web Design

then u have a mistake...  but it is unreasonable to ask someone to code by long distance via a forum for changes you want to make to your site...

we have no idea what you are coding..

Sorry, either you learn some php or employ someone to do this for you -- this is basic stuff.... 
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

Alexanderz

Maybe it's because I'm using a purchased theme? So it may work differently?
Yet, I have always used a guide in this forum for VM2 and had no problems. ( http://forum.virtuemart.net/index.php?topic=101797.0 )

However i repeat, you have been kind to help me  :)

Studio 42

#20
Quote from: GJC Web Design on March 06, 2016, 21:42:14 PM
then u have a mistake...  but it is unreasonable to ask someone to code by long distance via a forum for changes you want to make to your site...

we have no idea what you are coding..

Sorry, either you learn some php or employ someone to do this for you -- this is basic stuff.... 
I think it's the right answer. First learn PHP or find a developper.
THis is a basic problem, how you do the day your site is crashed, or your cart is not working anymore?

Alexanderz

I will follow your advice. Thank you for everything.