Keyword
Please note that official support for commercial extensions & templates is provided in the Subscriber Help Desk.
Support requests should ONLY be directed there and require an active subscription plan.
This forum board is to be used for archive purposes and knowledge exchange ONLY.

Display gallery in K2 category listing

  • Martin Šramko
  • Martin Šramko's Avatar Topic Author
  • Offline
  • New Member
More
9 years 7 months ago - 9 years 7 months ago #143791 by Martin Šramko
Display gallery in K2 category listing was created by Martin Šramko
Hi,
Is possible to display gallery in K2 category listing ?
Something like this :
<?php if($this->leading[0]->params->get('itemImageGallery') && !empty($this->leading[0]->gallery)): ?>
<!-- Item image gallery -->
	  <?php echo $this->leading[0]->gallery; ?>
<?php endif; ?>

Output from above code is only : {gallery}13{/gallery}

Thanks for help
Last edit: 9 years 7 months ago by Martin Šramko.

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

More
9 years 7 months ago #143796 by Lefteris
Replied by Lefteris on topic Display gallery in K2 category listing
Hi,

Yes, there is already an option for this in K2. You can find it in the category edit page. There is no need to add any extra code. The code is already included in K2 default templates: github.com/joomlaworks/k2/blob/master/components/com_k2/templates/default/category_item.php#L242-L248

JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

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


Powered by Kunena Forum