30% Discount Get your Kallyas WordPress license Today for only $49! Or renew your support at $18 for extra 6 months. Shop Now

Remove query string from static resources

To remove the query string from the static resources, please add the following code to your child theme’s functions.php file:

/*** Remove Query String from Static Resources ***/
function kc_removeQsFromLinks( $src ) {
    $src = preg_replace("/[;|?|&]ver=(.*)/mi", '', $src);
    return $src;
add_filter( 'style_loader_src', 'kc_removeQsFromLinks', 999 );
add_filter( 'script_loader_src', 'kc_removeQsFromLinks',999 );