- Posts: 8743
COMMUNITY FORUM
Attachments not working...cant download..
- Lefteris
- Offline
- Moderator
Less
More
10 years 4 months ago #128572
by Lefteris
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Replied by Lefteris on topic Re: Attachments not working...cant download..
Glad that you solved. Let me know if you face more issues.
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Pedro Henrique
- Offline
- New Member
Less
More
- Posts: 1
9 years 11 months ago - 9 years 11 months ago #128573
by Pedro Henrique
Replied by Pedro Henrique on topic Re: Attachments not working...cant download..
The Problem is in K2 attachment SEF URLs parser and/or generator. If you enable the "Category id and title alias separator", the Download URLs must be yourdomain.com/menu-alias/ID-CATEGORY-ALIAS/download/id_hash (Like www.domain.com/menu-alias/10-category-alias/download/20_9e847hfurh4449589302dd89). But K2 is not generating SEF URL well in this case, it is generating www.domain.com/menu-alias/download/20_9e847hfurh4449589302dd89 (without the id and category alias separator that you enabled in K2 SEF advanced configuration). When you click it, K2 don´t understand the link and throw a 404 error.
I made a workaround code for that, to force append the category id and category alias separator to the URL. You have to include this code in category_file.php and item.php K2 template files (this way we don´t hack K2 core files):
I made a workaround code for that, to force append the category id and category alias separator to the URL. You have to include this code in category_file.php and item.php K2 template files (this way we don´t hack K2 core files):
Log in or Create an account to join the conversation.
- Lefteris
- Offline
- Moderator
Less
More
- Posts: 8743
9 years 11 months ago #128574
by Lefteris
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Replied by Lefteris on topic Re: Attachments not working...cant download..
@Pedro Henrique
Hi. Can you test with the development version from getk2.org/assets/get ? There have been some changes to the router which should solve the issue. Let me know when you have any news on this.
Hi. Can you test with the development version from getk2.org/assets/get ? There have been some changes to the router which should solve the issue. Let me know when you have any news on this.
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.