Hi all!
I would like to get the customer ID on the product.php to call a custom pricing function.
I tried $customer_id = $this->customer->getId() but it returns a strange value (only 1 or 0, not the customer ID like 100111).
How should I use the function?
Thanks in advance.
Bye.
That will work.
Assuming the customer is logged in you need to check:
Assuming the customer is logged in you need to check:
Code: Select all
if ($this->customer->isLogged()) {
$cid = $this->customer->getId();
} else{
$cid = '';
}
Who is online
Users browsing this forum: No registered users and 6 guests