Skip to main content

Adding A Product Custom Field To Account Page

More
6 years 5 months ago #317762 by davec
-- HikaShop version -- : 4.2.3
-- Joomla version -- : 3.9.16

Hi

I am trying to add a custom field from the table product to the account page. I already have one field from table order which shows as per attachment of the view user / cpanel_orders.php.
Code:
<div> <?php echo $order->notes; ?></div>

I now have a text field of eta for the table product , which displays on the product listing and product page. Is it possible to add code so that it also display in the user cpanel? I did try this but it doesn't show <?php echo $product->eta; ?>

Thanks

Dave B)

Please Log in or Create an account to join the conversation.

More
6 years 5 months ago #317765 by nicolas
Hi,

The data is not loaded there.
So you need to load it yourself, like this:
Code:
$class = hikashop_get('class.product'); $data = $class->get($product->product_id); echo $data->eta;
The following user(s) said Thank You: davec

Please Log in or Create an account to join the conversation.

Time to create page: 0.196 seconds
Powered by Kunena Forum