Created
June 5, 2018 07:00
-
-
Save shameemreza/21d0fb0e07ff63a7a82d08154f29feaa to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Remove query strings from static resources | |
function shameem_remove_cssjs_ver( $src ) { | |
if( strpos( $src, '?ver=' ) ) | |
$src = remove_query_arg( 'ver', $src ); | |
return $src; | |
} | |
add_filter( 'style_loader_src', 'shameem_remove_cssjs_ver', 10, 2 ); | |
add_filter( 'script_loader_src', 'shameem_remove_cssjs_ver', 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment