Plugin changes theme folder styles version in frontend
-
At every use of cache clear this code runs and stores an option value for
theme
key.$time = time();
update_option( '_ccfm_style_timestamp_theme', $time );In
wp_head
two filters are set up:add_filter( 'style_loader_src', 'ccfm_show_src_version', 10, 2 );
add_filter( 'script_loader_src', 'ccfm_show_src_version', 10, 2 );The filter uses above
theme
key and changes thever
parameter in theme file urls to the timestamp of last cache clear time.function ccfm_show_src_version ( $src, $handle ) {
$key = ccfm_custom_src_key( $src );
$timestamp = get_option( '_ccfm_style_timestamp_' . $key, '' );
...
$query['ver'] = $timestamp;
return add_query_arg( $query, $src_parts[0] );
...
}This happens no matter what and can not be switched off.
Would expect the plugin to not change theme scripts/styles version in frontend output.
Clear Cache for Me 2.2, WordPress 6.6.2
PS. Please also update “tested up to” WordPress version.
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- You must be logged in to reply to this topic.