add a background image in aspnet to cover the entire screen

You need to use <body> with background-size:

cover:

Scales the image as large as possible without stretching the image. If the proportions of the image differ from the element, it is cropped either vertically or horizontally so that no empty space remains.

body { 
    background-image: url(~/data/backgroundimage.jpg); 
    background-repeat:no-repeat; 
    background-size:cover; 
}

See also: How to apply full background image in asp.net MVC

CLICK HERE to find out more related problems solutions.

Leave a Comment

Your email address will not be published.

Scroll to Top