Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
When I upload a picture with the article form using a site alias, the picture is uploaded in the "files/field/image" directory but pictures aren't resized in "files/styles/[thumbnail|medium|large]/public/field/image/" directories by the image core module. However, when I use the real URL, the resizing process works fine.
Comment | File | Size | Author |
---|---|---|---|
#1 | patch.txt | 7.04 KB | Thomas Bosviel |
Comments
Comment #1
Thomas Bosviel CreditAttribution: Thomas Bosviel commentedIn the file "includes/bootstrap.inc", I found this comment of "conf_path" function :
"If a file named sites.php is present in the $confdir, it will be loaded prior to scanning for directories. It should define an associative array named $sites, which maps domains to directories. [...] Since Drupal stores file paths into the database (files, system table, etc.) this will ensure the paths are correct while accessed on development servers."
I set up this new feature and picture upload works fine with site alias. So, I propose this patch to ensure the new Drupal's multi-site directory aliasing feature compatibility.
Comment #2
Thomas Bosviel CreditAttribution: Thomas Bosviel commentedComment #3
anarcat CreditAttribution: anarcat commentedOkay, this is pretty amazing stuff. I didn't even know about sites.php! :)
Does that mean that symlinks are not relevant in d7 anymore?
I think the patch looks good, I'll just merge it and we'll bite the bullet here. I tested aliases and it seemed to work fine...
One thing for the future though:
... that's what git apply tells me, try not to introduce whitespace changes in your patches...
Otherwise, this is committed and will be shipped in 1.0, thank you for this excellent patch!