Bachir Soussi Chiadmi a163542966 security update for uuid xmlsitemap file_field_path | 6 лет назад | |
---|---|---|
.. | ||
modules | 6 лет назад | |
tests | 6 лет назад | |
.travis.yml | 6 лет назад | |
CHANGELOG.txt | 6 лет назад | |
LICENSE.txt | 9 лет назад | |
README.md | 6 лет назад | |
filefield_paths.admin.inc | 6 лет назад | |
filefield_paths.api.php | 6 лет назад | |
filefield_paths.drush.inc | 6 лет назад | |
filefield_paths.info | 6 лет назад | |
filefield_paths.install | 6 лет назад | |
filefield_paths.module | 6 лет назад | |
filefield_paths.tokens.inc | 6 лет назад | |
filefield_paths.variable.inc | 6 лет назад |
The File (Field) Paths module extends the default functionality of Drupal's core File module, Image module and many other File upload modules, by adding the ability to use entity based tokens in destination paths and file names.
In simple terms, File (Field) Paths allows you to automatically sort and rename your uploaded files using token based replacement patterns to maintain a nice clean filesystem.
Once installed, File (Field) Paths needs to be configured for each file field you wish to use. Settings can be found on the settings form of any supported file based field.
Example:
Administration > Structure > Content types > Article > Manage fields > Image
http://example.com/admin/structure/types/manage/article/fields/field_image
Q. Aren't tokens already supported in the File module?
A. A limited selection of tokens are supported in the File module.
Entity based tokens allow you to use the Entity ID, Title, creation date and much more in your directory/filenames where you would otherwise be unable.
Q. Why aren't my files in the correct folder?
A. When you are creating or updating an entity the full values for the tokens may not yet be known by Drupal, so the File (Field) Paths module will upload your files to a temporary location and then once you save the entity and Drupal is provided with the tokens values the file will be moved to the appropriate location.
Q. Why is there a warning on the 'Retroactive updates' feature?
A. Retroactive updates will go through every single entity of the particular bundle and move and/or rename the files.
While there have been no reports of errors caused by the feature, it is quite possible that the moving/renaming of these files could break links. It is strongly advised that you only use this functionality on your developmental servers so that you can make sure not to introduce any linking issues.
File (Field) Paths was written and is maintained by Stuart Clark (deciphered).