Home > database >  how to add background image in a webpage
how to add background image in a webpage

Time:12-05

which tag we will use for adding the background image and how to remake it's size full length

I tried by using style tag in html of head section background-image:url;

CodePudding user response:

To add a background image on an HTML element, use the HTML style attribute and the CSS background-image property:

CodePudding user response:

In HTML, you can use the image tag to load the image, but to use the image for the background, you must use the background-image CSS.

CodePudding user response:

to add a background image and increase its size you need to use the following CSS

body{background-image: url(image); background-size: width height;}

it will add background image with desired width and heigth

  • Related