Cannot add version of main.css to wordpress on testing enviroment
To answer the question why you can’t add the theme’s version to your CSS file, it’s likely because the Version property of $theme is private so you cannot access it directly, but you can access it through the public get function. Try this instead: $theme = wp_get_theme(); define(‘THEME_VERSION’, $theme->get(‘Version’)); You also don’t need to add … Read more