- Posts: 8
COMMUNITY FORUM
Show SubCategory Items in category page
- Luigi
- Topic Author
- Offline
- New Member
Less
More
12 years 3 months ago #67281
by Luigi
Show SubCategory Items in category page was created by Luigi
I can show the subcategory's items like this:
MainK2Category
- SubK2Cat1
- k2Item 1
- k2Item 2
- SubK2Cat2
- k2Item 3
- k2Item 4
- k2Item 5
- SubK2Cat3
- k2Item 6
- k2Item 7
I need for help!
MainK2Category
- SubK2Cat1
- k2Item 1
- k2Item 2
- SubK2Cat2
- k2Item 3
- k2Item 4
- k2Item 5
- SubK2Cat3
- k2Item 6
- k2Item 7
I need for help!
Please Log in or Create an account to join the conversation.
- Lefteris
- Offline
- Moderator
Less
More
- Posts: 8743
12 years 3 months ago #67282
by Lefteris
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Replied by Lefteris on topic Re: Show SubCategory Items in category page
Hi. This cannot be done in K2 out of the box. You need to write code to achieve this.
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Luigi
- Topic Author
- Offline
- New Member
Less
More
- Posts: 8
12 years 3 months ago #67283
by Luigi
Replied by Luigi on topic Re: Show SubCategory Items in category page
You can help me?
Please Log in or Create an account to join the conversation.
- dezignas
- Offline
- Junior Member
Less
More
- Posts: 23
12 years 3 months ago - 12 years 3 months ago #67284
by dezignas
Replied by dezignas on topic Re: Show SubCategory Items in category page
I have same problem can you write any hint how to do that meaning a code :)
I'm not very good at php but I would think it could be something like this
<?php foreach($this->subCategories->item as $key=>$subitem): ?>
<div class="subCategoryContainer "<?php echo (count($this->subCategories)==1) ? '' : ' style="width:'.number_format(100/$this->params->get('subCatColumns'), 1).'%;"'; ?>>
<?php echo $subitem->link; ?>">
<?php echo $subitem->name; ?>
<?php endforeach; ?>
</div>
<?php endif; ?>
I'm not very good at php but I would think it could be something like this
<?php foreach($this->subCategories->item as $key=>$subitem): ?>
<div class="subCategoryContainer "<?php echo (count($this->subCategories)==1) ? '' : ' style="width:'.number_format(100/$this->params->get('subCatColumns'), 1).'%;"'; ?>>
<?php echo $subitem->link; ?>">
<?php echo $subitem->name; ?>
<?php endforeach; ?>
</div>
<?php endif; ?>
Please Log in or Create an account to join the conversation.
- dezignas
- Offline
- Junior Member
Less
More
- Posts: 23
12 years 3 months ago #67285
by dezignas
Replied by dezignas on topic Re: Show SubCategory Items in category page
anyone can help ?
Please Log in or Create an account to join the conversation.
- dezignas
- Offline
- Junior Member
Less
More
- Posts: 23
12 years 3 months ago #67286
by dezignas
Replied by dezignas on topic Re: Show SubCategory Items in category page
again anyone is it so hard to do ?
Please Log in or Create an account to join the conversation.
- dezignas
- Offline
- Junior Member
Less
More
- Posts: 23
12 years 3 months ago #67287
by dezignas
Replied by dezignas on topic Re: Show SubCategory Items in category page
anyone with help ? :)
Please Log in or Create an account to join the conversation.
- dezignas
- Offline
- Junior Member
Less
More
- Posts: 23
12 years 3 months ago #67288
by dezignas
Replied by dezignas on topic Re: Show SubCategory Items in category page
Can you help with this ? :)
Please Log in or Create an account to join the conversation.
- dezignas
- Offline
- Junior Member
Less
More
- Posts: 23
12 years 3 months ago #67289
by dezignas
Replied by dezignas on topic Re: Show SubCategory Items in category page
Are Me and luigi the only ones with this problem ? :)
Please Log in or Create an account to join the conversation.
- ibarreto
- Offline
- New Member
Less
More
- Posts: 5
11 years 7 months ago #67290
by ibarreto
Replied by ibarreto on topic Re: Show SubCategory Items in category page
Hi guys, did you find a solution for listing the items in the subcategories?
thanks
thanks
Please Log in or Create an account to join the conversation.