Keyword

[SOLVED] joomla sef & k2 download attachments error 404

  • stathis poularakis
  • stathis poularakis's Avatar Topic Author
  • Offline
  • New Member
More
12 years 10 months ago - 12 years 10 months ago #59209 by stathis poularakis
Hi, i recently did the big leap and started using joomla (1.5.22). I have a problem with k2 items (k2 2.5.1)

I have uploaded some attachment files but when i click ''download attachment'' i get the error 404-not found.

I have read that this is a known issue with sh404SEF and K2.

But i m not using sh404SEF, only joomla seo settings in global cofinguration. Does any one know any solution to this proble ....? thx

Please Log in or Create an account to join the conversation.

More
12 years 10 months ago #59210 by Marcio
Hello.. I´m using j1.7 and have the same issue. Do you have found a fix for it?

Thanks

Please Log in or Create an account to join the conversation.

More
12 years 9 months ago #59211 by CSN2011
I have the same problem too!!!

I am using Joomla! V1.7.3 and K2 V2.5.1.

The attachment link works fine in the administration area, but not on the website.

Any solutions?

Please Log in or Create an account to join the conversation.

More
12 years 9 months ago - 12 years 9 months ago #59212 by İsmail Kuzucu
Replied by İsmail Kuzucu on topic Re: joomla sef & k2 download attachments error 404
Yes, I too have the same error. 404 error is coming down, but the frontend admin panel file.

Seo seems linked to the setting as follows.
www.sitename.com/cate/item/download/4.html

Joomla version: 1.7.3
K2 version: 2.5.4

How can we fix the problem.
Thanks

Please Log in or Create an account to join the conversation.

More
12 years 9 months ago #59213 by Anthony Martin
Replied by Anthony Martin on topic Re: joomla sef & k2 download attachments error 404
Hi,

looks like this issue has been alive a while in various different posts across the site. Has anyone found a fix for it yet?

I've seen a thread saying that the downloads fail because of SH404, but that doens't seem to be true, the URL's fail even before SH404 takes control of the URL as K2 seems to be outputting the wrong URL in the first place.

from the backend this works fine and will access the download...

/administrator/index.php?option=com_k2&view=item&task=download&id=39_1eba6e274678040bad2ad3e82eac287a

in the front end, the K2 component creates this: /index.php?option=com_k2&view=item&task=download&id=39

Which is blatantly missing the "_1eba6e274678040bad2ad3e82eac287a" part.

As soon as I add these parts back together in th efront end the download works, so how / where do I change the output of the item in the front end to add this extra file information?

Please Log in or Create an account to join the conversation.

More
12 years 9 months ago #59214 by Anthony Martin
Replied by Anthony Martin on topic Re: joomla sef & k2 download attachments error 404
I've found the Solution (I Think)

It's not just the core template files within the K2 Component folder you need to worry about. There are also the overrides within the Core Joomla Template which force K2 to display in the way the site template designers intended - this is most likely that part which is still broken after you change the code Make sure you change the lines in the files within Templates / (Your Template Name) / Com_K2 / Default

To fix mine I just copied the entire directory from another template on another site I knew was working over the top of this folder.

Please Log in or Create an account to join the conversation.

More
12 years 9 months ago #59215 by Pavel Kouřil
Replied by Pavel Kouřil on topic Re: joomla sef & k2 download attachments error 404
Hello, I have the same problem like you. Could you send me please fix as you desrcribe in your post? I have not another template I knew was working. Thank you in advance This email address is being protected from spambots. You need JavaScript enabled to view it.

Please Log in or Create an account to join the conversation.

More
12 years 8 months ago #59216 by Novalee
I need the solution too, I have the same problem! Could you please send it to me via email to This email address is being protected from spambots. You need JavaScript enabled to view it.?
Thanks in advance!

Please Log in or Create an account to join the conversation.

  • Michelangelo Consiglio
  • Michelangelo Consiglio's Avatar
  • Offline
  • New Member
More
12 years 2 hours ago #59217 by Michelangelo Consiglio
Replied by Michelangelo Consiglio on topic Re: joomla sef & k2 download attachments error 404
Anthony, thanks a lot for the solution !!!!
,
I've had the same problem with a joomla 2.5 and K2 2.5 site.

As you suggested I checked and changed the template files.

My error was in the file item.php in the templates/[template name]/html/com_k2/templates/default directory.

I took the original row and changed the one in the template version.
My uncorrect row was:

<a title="<?php echo htmlentities($attachment->titleAttribute, ENT_QUOTES, 'UTF-8'); ?>" href="<?php echo JRoute::_('index.php?option=com_k2&view=item&task=download&id='.$attachment->id); ?>">

changed with the original

<a title="<?php echo K2HelperUtilities::cleanHtml($attachment->titleAttribute); ?>" href="<?php echo $attachment->link; ?>"> (line 376 - K2 ver. 2.5.7)

Please Log in or Create an account to join the conversation.

More
11 years 6 months ago #59218 by GFX
Thanks Dear
Its also word with me.
:)

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum