- Posts: 2
- Thank you received: 0
All questions about EDocman extension
SOLVED: Link to go up to parent category
- Till
- Topic Author
- Offline
- New Member
-
Less
More
10 years 11 months ago - 10 years 11 months ago #44956
by Till
SOLVED: Link to go up to parent category was created by Till
Hello Tuan,
first let me say, that I really like your component EDocman. Does just what I need it to do and such a nice code in the frontend.
I have just one simple question (I searched if the answer already existed, but didn't find anything):
If you are in a subcategory, do you have an option to show some link to go up to the parent category? I didn't find anything in the backend configuration. Also I couldn't find any such link in your demo pages. So I surmise you don't have it implemented.
So my - maybe not so simple - next question is: I want to integrate such a link in an override in "table.php". What would be the code for it? And I don't mean something like "history.go(-1)"
first let me say, that I really like your component EDocman. Does just what I need it to do and such a nice code in the frontend.
I have just one simple question (I searched if the answer already existed, but didn't find anything):
If you are in a subcategory, do you have an option to show some link to go up to the parent category? I didn't find anything in the backend configuration. Also I couldn't find any such link in your demo pages. So I surmise you don't have it implemented.
So my - maybe not so simple - next question is: I want to integrate such a link in an override in "table.php". What would be the code for it? And I don't mean something like "history.go(-1)"

Last edit: 10 years 11 months ago by Till. Reason: Marking as solved
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
10 years 11 months ago #44982
by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Link to go up from subcategory to parent category
Hi Till
Do you have breadcrumb module loaded on your site ? If you loaded that module into your site template (hope you know how to do that), you will be able to navigate to parent categories easily !
Tuan
Do you have breadcrumb module loaded on your site ? If you loaded that module into your site template (hope you know how to do that), you will be able to navigate to parent categories easily !
Tuan
The following user(s) said Thank You: Till
Please Log in or Create an account to join the conversation.
- Till
- Topic Author
- Offline
- New Member
-
Less
More
- Posts: 2
- Thank you received: 0
10 years 11 months ago - 10 years 11 months ago #45025
by Till
Replied by Till on topic Link to go up from subcategory to parent category
Yes, I do know how to integrate the breadcrumbs module. Pity that my client does not want it to be present on his website.
But still, thank you for your hint! I will look into the breadcrumbs module and see if I can re-use some of that code to generate such a "Up to parent category" link.
Update: My mother always told me to think before talking. Well, she was right... Here is the very simple code. Put it where you want the link to appear.
But still, thank you for your hint! I will look into the breadcrumbs module and see if I can re-use some of that code to generate such a "Up to parent category" link.
Update: My mother always told me to think before talking. Well, she was right... Here is the very simple code. Put it where you want the link to appear.
Code:
<?php if ($this->category->parent_id != 0)
{
?>
<a href="<?php echo JRoute::_('index.php?option=com_edocman&view=category&id='.$this->category->parent_id.'&layout=table&Itemid='.$this->Itemid); ?>">YOUR_LINKTEXT</a>
<?php
}
?>
Last edit: 10 years 11 months ago by Till.
Please Log in or Create an account to join the conversation.
- Tuan Pham Ngoc
- Offline
- Administrator
-
10 years 11 months ago #45065
by Tuan Pham Ngoc
Replied by Tuan Pham Ngoc on topic Link to go up from subcategory to parent category
Yeah, that's a very simple solution and it works. Breadcrumb will make it more flexible (allowing to navigate to any parent category - in case you have categories in different levels). But I guess the above code is OK for your usecase !
Tuan
Tuan
Please Log in or Create an account to join the conversation.
Moderators: Mr. Dam
Support
Documentation
Information
Copyright © 2025 Joomla Extensions by Joomdonation. All Rights Reserved.
joomdonation.com is not affiliated with or endorsed by the Joomla! Project or Open Source Matters.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.