Hi
I've installed the download manager on my site but the path to the images/icons is incorrect. It's looking for images at
myurl.com/mounted-storage/plugins/serendipity_event_downloadmanager/img/xxx.png
'mounted-storage' seems to have been added to the actual path.
Any ideas how I can change this?
Dave
download manager image/icon path incorrect
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: download manager image/icon path incorrect
Hi!
Did you look into the downloadmanagers plugin configuration? I beleive there you can adjust paths.
HTH,
Garvin
Did you look into the downloadmanagers plugin configuration? I beleive there you can adjust paths.
HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Hi Garvin
I don't think i explained well enough what's wrong so I've done a screenshot to show which icon images are missing. It's the path to these missing icons that has an unwanted 'mounted-storage/' in.

thanks
Dave
first place I looked - you can only adjust the paths to the folders the plugin uses for uploading and downloading files.Did you look into the downloadmanagers plugin configuration
I don't think i explained well enough what's wrong so I've done a screenshot to show which icon images are missing. It's the path to these missing icons that has an unwanted 'mounted-storage/' in.
thanks
Dave
-
mgroeninger
- Regular
- Posts: 546
- Joined: Mon Dec 20, 2004 11:57 pm
- Contact:
I think the problem is the getRelPath() function (I'll post it below). I don't actually ever use this plugin, so I'm not sure of all its intricacies, but it appears to call this function everytime it generates an output path.
I would think there is a simpler way to do it, but I'm guessing, especially since I haven't looked at why it was done this way...
Alexander's last post was back in May, so I'm not sure he is following the forums anymore... I might try to figure out what he is using this for, but it will take me a little while...
Code: Select all
function getRelPath() {
global $serendipity;
$c_path = dirname(__FILE__);
$b_path = $serendipity['serendipityPath'];
if ($b_path[(strlen($b_path)-1)] == "/")
$b_path = substr($b_path, 0, strlen($b_path)-1);
$r_path = ".".str_replace($b_path, "", $c_path);
return $r_path;
}Alexander's last post was back in May, so I'm not sure he is following the forums anymore... I might try to figure out what he is using this for, but it will take me a little while...
Matthew (Feeling generous?)
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Hi!
I think we will need to introduce a new variable to configure the HTTP path to the plugin, like in other plugins. Theres technical no save way to deduce a filesystem path into a HTTP path, so you need to enter it.
I can look into that after my holiday.
Best regards,
Garvin
I think we will need to introduce a new variable to configure the HTTP path to the plugin, like in other plugins. Theres technical no save way to deduce a filesystem path into a HTTP path, so you need to enter it.
I can look into that after my holiday.
Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Hi
I've temporarily partially 'fixed' this so that it works on my site by setting $r_path as followsIt works for the folder icons but the plugin seems unable to detect the filetype and allocate the correct icon to the file. But at least my clients can download.
My themes site also uses this plugin and I have no path issues there at all. I'm running Serendipity v.1.0 on the themes site and v1.1alpha4 on my company site.
cheers
Dave
I've temporarily partially 'fixed' this so that it works on my site by setting $r_path as follows
Code: Select all
$r_path = "http://mywebsite.com/plugins/serendipity_event_downloadmanager";My themes site also uses this plugin and I have no path issues there at all. I'm running Serendipity v.1.0 on the themes site and v1.1alpha4 on my company site.
cheers
Dave
since you had posted this info and i had the time to look @ it and wanted this to work correctly i figured i'd take a shot @ it myself. i don't know anything about php, code or anything of the sort BUT, i did notice that the "." in this statement was being put in the path of the missing pictures: $r_path = ".".str_replace($b_path, "", $c_path); and all i did was delete it from the php file, save it and viola! it worked!mgroeninger wrote:I think the problem is the getRelPath() function (I'll post it below). I don't actually ever use this plugin, so I'm not sure of all its intricacies, but it appears to call this function everytime it generates an output path.
I would think there is a simpler way to do it, but I'm guessing, especially since I haven't looked at why it was done this way...Code: Select all
function getRelPath() { global $serendipity; $c_path = dirname(__FILE__); $b_path = $serendipity['serendipityPath']; if ($b_path[(strlen($b_path)-1)] == "/") $b_path = substr($b_path, 0, strlen($b_path)-1); $r_path = ".".str_replace($b_path, "", $c_path); return $r_path; }
Alexander's last post was back in May, so I'm not sure he is following the forums anymore... I might try to figure out what he is using this for, but it will take me a little while...
thanks for posting the info.