-
Notifications
You must be signed in to change notification settings - Fork 4.6k
Closed
Labels
Needs DecisionNeeds a decision to be actionable or relevantNeeds a decision to be actionable or relevant[Feature] Font Library[Priority] HighUsed to indicate top priority items that need quick attentionUsed to indicate top priority items that need quick attention[Status] In ProgressTracking issues with work in progressTracking issues with work in progress
Description
In #53965 the decision was made to use the wp-content/fonts directory for uploaded fonts rather than wp-content/uploads/fonts.
Following this discussion in Slack about the Font Library, this decision should be reassessed. There are pros and cons for using wp-content/fonts versus using a fonts directory within the uploads directory, some of which are technical.
Notes
wp-content/uploads/fontsis referred to in this issue but technically this means thefontssubdirectory within the configured uploads directory.- This is separate to the discussion about treating uploaded fonts as attachments. Files can be uploaded to the uploads directory without having to be associated with an attachment.
- The
fontsdirectory could be namedwp-fontsor something else to minimise the chance of a conflict with a directory used by an existing font management plugin, that's not a concern for this issue. - The "pros" of using
wp-content/fontsseem to be more philosophical, whereas the "cons" seem to be more technical.
Arguments in favour of wp-content/fonts
- We should keep uploads for things you insert into posts.
- If we end up adding folders to media library and someone adds a "fonts" folder for some reason.
- The upload folder being
wp-content/fontswas an explicit design decision to treat the font library as a distinct resource, not coupled with media as a representation.
Arguments in favour of wp-content/uploads/fonts
- Directories outside of
wp-content/uploadsmay not be writable, either as a security measure or due to offloading uploaded media to a CDN- This is potentially a blocker
- A discussion on this topic has been started in the #hosting channel in Slack
- This has been raised previously
- The decision to store fonts outside the uploads folder is problematic for immutable file systems and set ups in which user uploads are offloaded. It's not simply a case of making the directory writable, plugins will need to be updated, servers reconfigured.
- This could affect high impact hosts such as WordPress VIP, any site using security hardening plugins, or any site using
DISALLOW_FILE_MODS
- Font files are uploaded by users, therefore it makes sense to place the uploaded files within the uploads directory
- Personal data export files are placed within the uploads directory. Even though there is no specific discussion on that decision in the core Trac ticket for that feature, it's likely this was done for the technical reasons above.
Please comment with any further arguments in favour or against either location.
Metadata
Metadata
Assignees
Labels
Needs DecisionNeeds a decision to be actionable or relevantNeeds a decision to be actionable or relevant[Feature] Font Library[Priority] HighUsed to indicate top priority items that need quick attentionUsed to indicate top priority items that need quick attention[Status] In ProgressTracking issues with work in progressTracking issues with work in progress