We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent aa7852c commit 8507d59Copy full SHA for 8507d59
src/wp-includes/theme.php
@@ -1953,11 +1953,13 @@ function _custom_background_cb() {
1953
1954
$style .= $image . $position . $size . $repeat . $attachment;
1955
}
1956
- ?>
1957
-<style<?php echo $type_attr; ?> id="custom-background-css">
1958
-body.custom-background { <?php echo trim( $style ); ?> }
1959
-</style>
1960
- <?php
+
+ $processor = new WP_HTML_Tag_Processor( "<style{$type_attr} id=\"custom-background-css\"></style>" );
+ $processor->next_tag();
+ $style_tag_content = 'body.custom-background { ' . trim( $style ) . ' }';
1961
+ $processor->set_modifiable_text( "\n{$style_tag_content}\n" );
1962
+ echo $processor->get_updated_html();
1963
1964
1965
/**
0 commit comments