Keyword

Local file doesn't exist.

More
11 years 1 month ago - 11 years 1 month ago #112578 by cyberbill
Replied by cyberbill on topic Re: Local file doesn't exist.
Just ran into this. May need this in more than just this one place, but needed quick fix.
Running v2.6.7

In: administrator/components/com_k2/models/item.php

file is stored in DB with full path eg: /var/www/html/... ($attachment->filename)

then $savepath is being prepended to it.

Line 1066:
Before:
$file = $savepath.DS.$attachment->filename;

After: (make sure we stay in JPATH_ROOT to avoid pulling system files)
$file = $attachment->filename;
if (strpos($file, JPATH_ROOT) !== 0) {
    $file = $savepath.DS.$attachment->filename;
}

Added to Issue tracker:
code.google.com/p/getk2/issues/detail?id=624

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

More
11 years 1 month ago #112579 by lydianp18
Replied by lydianp18 on topic [SOLVED] Re: Local file doesn't exist.
Whooo!!! That fixed it for me!

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

More
10 years 2 months ago #112580 by Jo
Replied by Jo on topic Re: Local file doesn't exist.
Thank you!

Been searching for hours and this is the only fix that worked for me .

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


Powered by Kunena Forum