Filters the `css` (`post_content`) and `preprocessed` (`post_content_filtered`) args for a `custom_css` post being updated. This filter can be used by plugin that offer CSS pre-processors, to store the original pre-processed CSS in `post_content_filtered` and then store processed CSS in `post_content`. When used in this way, the `post_content_filtered` should be supplied as the setting value instead of `post_content` via a the `customize_value_custom_css` filter, for example: <code> add_filter( 'customize_value_custom_css', function( $value, $setting ) { $post = wp_get_custom_css_post( $setting->stylesheet ); if ( $post && ! empty( $post->post_content_filtered ) ) { $css = $post->post_content_filtered;
$data, array_merge( $args, compact( 'css'
Sortie :
@param array $data {
@param array $args {
// Modifier la valeur avec le filtre 'update_custom_css_data'
add_filter('update_custom_css_data', 'ma_fonction_filtre', 10, 1);
function ma_fonction_filtre($data) {
// Modifier la valeur
return $data;
}
Chargement des actualités...