[civicrm.files] token doesn't work in some cases since 5.27
Broadly there have been 2 reports 1 from gharris in mattermost and also @justinfreeman has reported issues on a site where the usage of [civicrm.files]
token in the urls broke the site (likely extension related)
I proposed this https://github.com/civicrm/civicrm-core/pull/17868 as a fix but not likely to get merged
@totten suggested that sites affected run the following script locally https://gist.github.com/totten/5997ff53088b159e7275f761e52f9516 and reporting the findings back
Edit by kcristiano steps to reproduce:
- Have a WP CiviCRM on a version <= 5.26.2
- use the 'legacy' files location
/wp-content/plugins/files/civicrm
- use
[civicrm.files]
in Resource URL and directory UI screens (as these will be saved incivicrm_settings
) - Upgrade to 5.27.x
After upgrade [civicrm.files]
resolves to /wp-content/uploads/civicrm
Work around is to set the Resource URLs and Directories to the legacy locations in the UI screens or in overrides in civicrm.settings.php
Edited by kcristiano