Closed (fixed)
Project:
Embedded Media Field
Version:
6.x-1.x-dev
Component:
Embedded Video Field
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
18 Aug 2009 at 14:06 UTC
Updated:
5 Oct 2009 at 20:20 UTC
Jump to comment: Most recent file
Comments
Comment #1
srobert72 commentedThis issue looks like another one in "site_map" module.
Could you check if it is a bug or not ?
In this comment commiter explain his fix :
http://drupal.org/node/545762#comment-1951108
Comment #2
Nick Robillard commentedI'm getting this too.
Here's the problem in the generated markup:
Specifically, src="//sites/sitename/files/Image_3_1.png"
It's like base_path() is getting prepended twice (when i remove one of the / with Firebug, it works). My path in Emfield Video configuration is relative, just like srobert72's - sites/sitename/files/Image_3_1.png - no leading /.
Something else that is misleading is the path example in the Default thumbnail path field description:
Path to a local default thumbnail image for cases when a thumbnail can't be found. For example, you might have a default thumbnail at files/thumbnail.png.
Judging by the path that is output, that example should say sites/sitename/files/thumbnail.png instead of files/thumbnail.png
The default thumbnail functionality needs some work. (changing to bug report)
Comment #3
Nick Robillard commentedI've dug into the code and base_path() is being added to the path before it goes through theme_image() - which handles relative paths.
Current
Starting at line 87 of emvideo.theme.inc:
Removing base_path() fixes this.
Fixed
Line 91
Comment #4
Nick Robillard commentedAlso, it'd be nice to see line 341 of emvideo.module updated so that the description text is not misleading.
Currently
$description = t("Path to a local default thumbnail image for cases when a thumbnail can't be found. For example, you might have a default thumbnail at %files.", array('%files' => 'files/thumbnail.png'));
Proposed
$description = t("Path to a local default thumbnail image for cases when a thumbnail can't be found. For example, you might have a default thumbnail at %files.", array('%files' => 'sites/sitename/files/thumbnail.png'));
(updating status to Needs Review)
Comment #5
Nick Robillard commentedHere is a patch that applies the fix from #3.
(patched against 6.x-1.x-dev from 2009-Aug-27)
Comment #6
srobert72 commentedPatch from #5 that applies the fix from #3 works correctly for me.
It resolves my issue.
Now thumbnail is correctly looked for in this path :
http://www.mydomain.com/drupal/files/video_thumbnail.png
And my Emfield settings are :
Default thumbnail path :
files/video_thumbnail.pngSo fix proposed in #4 isn't necessary in my case.
I would be great if maintainer could include this patch in 6.x-1.x-dev release.
Comment #7
Nick Robillard commentedRight. In your case it isn't.
The reason is because theme_image() passes the path through url().
In url(), we have this:
I still propose the change in #4 though, because on 90% of Drupal setups, the "files" dir is under "sites" and a custom $base_url isn't defined as you have done. So I'm thinking the sites/sitename/files/thumbnail.png path suggestion would still be more accurate for most situations.
Comment #8
srobert72 commentedNew release 6.x-1-x-dev (2009-Sept-02) doesn't include patch in #5
Is it possible to maintainer to commit it for next DEV release ?
Comment #9
aaron commentedthis has been fixed now. thanks for the help!