-
AuthorPosts
-
kubii Friend
kubii
- Join date:
- September 2012
- Posts:
- 55
- Downloads:
- 0
- Uploads:
- 23
- Thanks:
- 18
- Thanked:
- 6 times in 1 posts
November 21, 2012 at 12:12 pm #182456Hi Folks,
Do you know how to show the “ItemListCategory” that appears in the “ItemListCategoryBlock” not only in category view, but in Article view aswell?
I would like the user to see the category details in the top, when he clicked on an article…
Hope to hear from you soon!
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
kubii Friendkubii
- Join date:
- September 2012
- Posts:
- 55
- Downloads:
- 0
- Uploads:
- 23
- Thanks:
- 18
- Thanked:
- 6 times in 1 posts
December 5, 2012 at 1:37 pm #475262Hello Saguaros,
thank you for your answer. In the meanwhile I tried to fix it myself, without any succes.I would like to have the same square box, that is filled with the k2 category description (example) in the article view aswell.
In the article view (example) the box already exists, but is filled with “print&email”.
I would like to see the k2 description of the Article, and the Article name in this grey box.Hope to hear from you soon!
Saguaros ModeratorSaguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
December 10, 2012 at 3:15 am #475652Hi kubii,
I’m very sorry for this late response, somehow I missed.
For this issue, could you make some screenshots of what you wanna achieve? since I cannot access 2 above sample links.
kubii Friendkubii
- Join date:
- September 2012
- Posts:
- 55
- Downloads:
- 0
- Uploads:
- 23
- Thanks:
- 18
- Thanked:
- 6 times in 1 posts
December 12, 2012 at 3:01 pm #476005Hi Saguaros
thanks for the reply! Sorry I deleted the category, as I was testing…
Sure, there you go:
Category View ( Here is the URL )Article View ( here is the URL )
-
Saguaros Moderator
Saguaros
- Join date:
- September 2014
- Posts:
- 31405
- Downloads:
- 237
- Uploads:
- 471
- Thanks:
- 845
- Thanked:
- 5346 times in 4964 posts
December 13, 2012 at 4:32 am #476074Hi kubii,
I got your idea, however this needs some customization / hack in code in this K2 component. My temporary idea is that you should open code file which defines template view for K2 category:
/components/k2/templates/default/category.phpFind code to display category info:
[PHP]
<?php if(isset($this->category) || ( $this->params->get(‘subCategories’) && isset($this->subCategories) && count($this->subCategories) )): ?>
<!– Blocks for current category and subcategories –>
<div class=”itemListCategoriesBlock”><?php if(isset($this->category) && ( $this->params->get(‘catImage’) || $this->params->get(‘catTitle’) || $this->params->get(‘catDescription’) || $this->category->event->K2CategoryDisplay )): ?>
<!– Category block –>
<div class=”itemListCategory”>
<?php if(isset($this->addLink)): ?>
<!– Item add link –>
<span class=”catItemAddLink”>
<a class=”modal” rel=”{handler:’iframe’,size:{x:990,y:650}}” href=”<?php echo $this->addLink; ?>”>
<?php echo JText::_(‘K2_ADD_A_NEW_ITEM_IN_THIS_CATEGORY’); ?>
</a>
……………….
</div>
<?php endif; ?>
[/PHP]and copy to file defining template view for K2 item: /components/k2/templates/default/item.php
It’s just my suggestion, please post your queries to K2 forum, they may give you better solution.
Best of luck.
kubii Friendkubii
- Join date:
- September 2012
- Posts:
- 55
- Downloads:
- 0
- Uploads:
- 23
- Thanks:
- 18
- Thanked:
- 6 times in 1 posts
December 17, 2012 at 2:49 pm #476528Thank you saguaros, after editing the code, I could not see any changes whatsoever 🙁
(Besides a 500 server error, which was caused by a faulty line of code)I posted a question in the k2 forum… I’ll keep you guys posted.
-
AuthorPosts
Viewing 7 posts - 1 through 7 (of 7 total)This topic contains 7 replies, has 2 voices, and was last updated by kubii 11 years, 11 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum
Jump to forum