- Posts: 35
COMMUNITY FORUM
Display tag pages same as category pages
- Ralf Longwitz
- Topic Author
- Offline
- Junior Member
This has come up before, similarly, but I hope there is a simpler solution for it:
I have the category display of my items set up, looks fine. Now I also want to set items into the menu by tag, easy enough. But the display of items by tag is totally different from the display by category - I need both to look exactly the same.
Is there an easy way to do this? Rather than overriding tag.php and reprogramming it all from almost scratch ...
The tag page display override should also automatically adjust to any parameter changes for categories. Is that possible with reasonable effort?
Thank you!
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
- Posts: 15920
Unfortunately I will let you down.
Since these are different views you will need to override the tag.php file.
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Ralf Longwitz
- Topic Author
- Offline
- Junior Member
- Posts: 35
Maybe a future feature? I've had this issue before, and I think I totally reworked tag.php then, years ago ...
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
- Posts: 15920
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Villy Koutsogianni
- Offline
- New Member
- Posts: 19
I totally agree with Ralf!!The tag page display override should also automatically adjust to any parameter changes for categories. Is that possible with reasonable effort?
I have tried to configure tag.php file but with no success, as I am not very familiar with it.
I am following the discussion at github but there are no updates there :(
Is there somebody that can help?
Thanks
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
- Posts: 15920
Unfortunately this is a feature which requires feedback and also it requires several hours of development.
You can comment on the thread so it receives more feedback.
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Villy Koutsogianni
- Offline
- New Member
- Posts: 19
Any suggestion?
Thanks
<span><?php echo JText::_('Also tagged under:'); ?></span>
<ul class="catItemTags">
<?php foreach ($this->item->tags as $tag): ?>
<a href="<?php echo $tag->link; ?>"><?php echo $tag->name; ?></a>,
<?php endforeach; ?>
</ul>
<div class="clr"></div>
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
- Posts: 15920
By default the tags are not available in this view github.com/getk2/k2/blob/master/components/com_k2/models/item.php#L96
You can add them to the tags by adding the appropriate view check || ($view == 'itemlist' && $task == 'tag')
and the tags will be available.
PS, You are missing a <li> tag.
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Villy Koutsogianni
- Offline
- New Member
- Posts: 19
I will give it a try
Please Log in or Create an account to join the conversation.
- Villy Koutsogianni
- Offline
- New Member
- Posts: 19
if it Is not too much to ask, could you provide me the code that should be added to tag.php?
Thank you
Please Log in or Create an account to join the conversation.