Posted by stBorchert on October 11, 2012 at 9:42am
8 followers
Jump to:
| Project: | File (Field) Paths |
| Version: | 7.x-1.0-beta3 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed (duplicate) |
Issue Summary
After activating "File (Field) Paths" and saving the settings for a (file|image) field, the settings "file_directory" is set to the value entered in the ffp-settings ("file_path").
Modules, relying on "file_directory" (e.g. "Media") therefore fail to upload the files into the correct directories.
Any suggestions on how to fix this? At the moment I undo $form['instance']['settings']['file_directory']['#access'] = FALSE; (filefield_paths.module L26) in a custom module to allow entering the directory.
Comments
#1
Hi, I have the same problem, when using file with the media module (media selector widget), the file(field)path directory is completely ignored. Could you explain what exactly goes wrong, cause I don't get it.
#2
After much time debugging (with my limited knowledge of PHP and Drupal inner workings) I noticed that the Feeds module also has this problem, because it calls file_field_widget_uri somewhere along the line.
I think a better approach would be if filefield_paths intercepts the file_field_widget_uri function and provides a version that takes the different file path location into account.
I'm sorry I'm unable to write such a module.
#3
Sure you're not being stung by #1854450: File Field Paths not working (not uploading to proper directory) ?
#4
Marking this as a duplicate of #1572206: Is it possible to disable FFP for a certain field?, not because it's the same issue, but because the solution in that issue should resolve this issue (allow you to disable File (Field) Paths on a Media field and set 'file_directory').