Skip to content

Header Image URL not Handled #37

@mikeselander

Description

@mikeselander

When using Tachyon, a single header image doesn't have its image URL tachyoned.

This appears to be because a single header image is never passed through image_downsize - it is called directly from get_theme_mod where the URL is saved as text. Ref: https://github.com/WordPress/WordPress/blob/master/wp-includes/theme.php#L1052

It looks like this can be filtered via get_header_image_tag or, even better via theme_mod_header_image.

For randomized headers, we might want to filter wp_get_attachment_url as they pass through a different function. This doesn't appear to pass through image_downsize but I might be missing something.

Worth noting: the srcset for the header image is correctly techyoned, it's the main header image URL that is incorrect.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions