Custom Background by Page IDs
I use TwentyTwent theme and want to change its background colour by page IDs.
I'm not sure but when I check the functions.php, I see below lines which are related to background colours:
// Custom background color.
add_theme_support(
'custom-background',
array(
'default-color' = 'f5efe0',
)
);
// Add the background option.
$background_color = get_theme_mod( 'background_color' );
if ( ! $background_color ) {
$background_color_arr = get_theme_support( 'custom-background' );
$background_color = $background_color_arr[0]['default-color'];
}
$editor_color_palette[] = array(
'name' = __( 'Background Color', 'twentytwenty' ),
'slug' = 'background',
'color' = '#' . $background_color,
);
Is there any simple way to change the background colour according to Page's ID?
Regards.
Topic child-theme custom-background php css customization Wordpress
Category Web