Whats the best way to bust cache using child theme for enfold? I’m not using wp_enqueue_scripts action and use wp_enqueue_style() in my function.php file.
thanks in advance
Hey laurenceanthony.nc,
I’m not sure what you mean by “bust cache”, could you try to explain a bit further please?
Best regards,
Rikard
HI Rikard,
To force a user’s browsers to clear cache
thanks,
Larry
Hi Larry,
Referring on wordpress’ wp_enqueue_script or wp_enqueue_style: https://developer.wordpress.org/reference/functions/wp_enqueue_style/
For example:
wp_enqueue_style( string $handle, string $src = '', array $deps = array(), string|bool|null $ver = false, string $media = 'all' )
You can take advantage of the version parameter and pass in a new version number every time you update your css file or scripts.
This will force the browser to fetch the css/script with that version number.
Best regards,
Nikko