Name

background-attachment

Synopsis

This property defines whether the background image scrolls along with the element when the document is scrolled. This can be used to create “aligned” backgrounds; see Chapter 9 for more details.

Values:

scroll | fixed | inherit

Initial value:

scroll

Applies to:

all elements

Inherited:

no

Computed value:

as specified

Get Cascading Style Sheets: The Definitive Guide, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.