CSS BACKGROUND IMAGE
A background image in CSS is added using the background-image property. Basic Syntax selector { background-image: url ( "image.jpg" ); } Example 1: Background Image <!DOCTYPE html> <html> <head> <style> body { background-image: url ( "background.jpg" ); } </style> </head> <body> <h1> Welcome </h1> </body> </html> Example 2: No Repeat body { background-image: url ( "background.jpg" ); background-repeat: no-repeat ; } Example 3: Full-Screen Background body { background-image: url ( "background.jpg" ); background-repeat: no-repeat ; background-size: cover ; background-position: center ; background-attachment: fixed ; } Example 4: Image Covering a <div> . box { width: 400 px ; height: 300 px ; background-image: url ( "nature.jpg" ); background-size: cover ; background-position: center ; } Common Background Image P...