Last active
December 3, 2016 00:13
-
-
Save edward-jimenez/974be051dec3bc29dba54f746ef556f6 to your computer and use it in GitHub Desktop.
Version your style.css file in WordPress
This file contains hidden or 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
| <?php | |
| /* | |
| Add this function to your fuctions.php to | |
| version your style.css. Make sure to | |
| define a constant to hold your CSS version. | |
| */ | |
| define( 'OUR_APP_VERSION', '2.0' ); | |
| function prefix_default_style( $styles ) { | |
| /* Use our default version style */ | |
| $styles->default_version = OUR_APP_VERSION; | |
| } | |
| add_action( 'wp_default_styles', 'prefix_default_styles' ); | |
| ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment