Hide Buy Button if not logged in
Posted: Mon Sep 18, 2023 3:04 am
Hi Everyone,
Sorry, its been a few years since I have played around with my store and have forgotten most of what I had learnt...
I feel like this should be an easy one that people have done multiple times before, but I just cant get it...
I want to hide the Buy button if a customer is not logged in.
I have added;
to the top of tpl_cm_pi_buy_button.php but this is generates an unexpected if statement error.
any help would be appreciated
Sorry, its been a few years since I have played around with my store and have forgotten most of what I had learnt...
I feel like this should be an easy one that people have done multiple times before, but I just cant get it...
I want to hide the Buy button if a customer is not logged in.
I have added;
Code: Select all
if ( isset($_SESSION['customer_id']) ) {any help would be appreciated