Site logo

Archived topic

Parent Theme Versioning

1 reply · Started by Anonymous on August 5, 2016

Viewing posts 1–2 of 2

Hey there,

The following stylesheet enqueue function for child themes is not working as intended. It seems the filemtime function is getting stuck and isn't updating upon file change. The end result is that the child stylesheet changes never show up unless you manually set the version parameter to false in the GeneratePress parent theme. Any idea whats going on?

// Add the child theme CSS if child theme is active.
if ( is_child_theme() )
	wp_enqueue_style( 'generate-child', get_stylesheet_uri(), true, filemtime( get_stylesheet_directory() . '/style.css' ), 'all' );

Hi there,

Just so I'm clear, you're not adding this into your child theme, correct? You're saying this code in the core theme isn't working as it should?

I'll take a look at it :)

This archived topic is closed to new replies.