Skip to content

Font Library: Support alternate paths for fonts (WP_FONTS_DIR) #55063

@jazzsequence

Description

@jazzsequence

What problem does this address?

For sites hosted on webhosts with immutable filesystems, installing fonts into wp-content is not a straightforward process unless those files are committed to an environment without those file write restrictions and deployed upstream. Providing a constant (or a filter) where a safe path can be defined allows users (or hosts) to be able to install fonts natively as intended without running into filesystem permission issues.

What is your proposed solution?

Introducing a constant, e.g. WP_FONTS_DIR which, like WP_CONTENT_DIR or WP_UPLOADS_DIR, allows a user to explicitly define an alternate path to installed fonts which is used instead of the default path (wp-content/fonts).

Metadata

Metadata

Labels

[Feature] TypographyFont and typography-related issues and PRs[Status] In ProgressTracking issues with work in progress[Type] BugAn existing feature does not function as intended

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions