Display category fields on product page

  • Posts: 171
  • Thank you received: 9
9 years 5 months ago #234737

-- HikaShop version -- : 2.6.1

Hi!

Is there a more flexible way to display category fields on product page as well, then

if(!empty($this->categories)){
	foreach($this->categories as $category){
		$kategoria = $category->category_id;
	}
}
$categoryClass = hikashop::get('class.category');
$category = $categoryClass->get($kategoria);

and then loading all values with:
<?php echo $category->FIELDNAME; ?>

Beacuse for example later fields can be extended, and for example when loading an ajax image field it just loads the image name. So this is not really an easy way.

Thanks in advance!

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

  • Posts: 12953
  • Thank you received: 1778
9 years 5 months ago #234749

Hello,

1. It will depend on where you exactly want to display it and in which file.

2.

Beacuse for example later fields can be extended, and for example when loading an ajax image field it just loads the image name. So this is not really an easy way.

I didn't understood about what you were talking, so can you give us more information about it through some screenshots for example so that we can understand and reproduce it on our end ?

Thank you.

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

Time to create page: 0.049 seconds
Powered by Kunena Forum