wpseek.com
Un motore di ricerca WordPress per sviluppatori e autori di temi
wp_custom_css_cb › WordPress Function
Da4.7.0
Deprecaton/a
› wp_custom_css_cb ( Nessun parametro )
| Definito a: |
|
| Codex: |
Renders the Custom CSS style element.
Funzioni correlate: wp_get_custom_css, wp_get_custom_css_post, wp_custom_css_has_value, wp_custom_css_kses_init, wp_update_custom_css_post
Sorgenti
function wp_custom_css_cb() {
$styles = wp_get_custom_css();
if ( ! $styles && ! is_customize_preview() ) {
return;
}
$processor = new WP_HTML_Tag_Processor( '<style></style>' );
$processor->next_tag();
$processor->set_attribute( 'id', 'wp-custom-css' );
$processor->set_modifiable_text( "\n{$styles}\n" );
echo "{$processor->get_updated_html()}\n";
}