About Background and Themes

The background feature is primarily intended for use in site pages and slots. Backgrounds set for pages and slots are meant to be configured by users, not developers, at the theme level.

Background effects can be configured in theme slots, however, these effects may override any background effects set for pages when editing a site.

The background feature does not alter themes or constituent theme files. A theme can’t be altered by the background settings for a page, and another page based on the same layout in a site won’t inherit any of the background settings for the source page. Adding or changing the background through a theme requires an update to the theme.

Users can configure different backgrounds on every page of the site, and also on different pages that use the same layout. This would not be possible within a theme. Although a theme may specify a background for a page, users’ background settings can override this specification. (Background settings will only apply overrides for a particular page; it does not in any way modify the theme itself.)

Be careful to avoid having the theme override background styles that will be set up in site pages and slots by users. This can happen in several ways:

  • Page background settings in a site can be overridden by a theme when you use element-based "style" attributes on the <body> and the slots.

  • Page background settings in a site can be overridden by a theme when you mark theme background styles as "!important" in the theme cascading style sheet (CSS) file.

See Change the Background or Theme in Building Sites with Oracle Content Management.