Home > OS >  how to add image to the section
how to add image to the section

Time:06-27

I am new to web development and i am using pre-built template and the below code is showing like the blow image and I am trying to replace it but not able to do. how to replace the background image enter image description here

<section id="cta" >
    <div >
        <div >
            <div >
                <h2>BLOGGER</h2>
                 </div>

        </div>
    </div>
</section>

CodePudding user response:

This might help you :)

<html>
    <head>
        <style>
        #cta{
        background-image:url("Here input your image path..");
        }
        </style>
    </head>
<body>
<section id="cta" >
    <div >
        <div >
            <div >
                <h2>BLOGGER</h2>  <!-- you can just remove it..Since this is not background image but a heading-->
                 </div>
        </div>
    </div>
</section>
</body>
</html>

CodePudding user response:

the background is set in css. need to know your css. you can try to overwrite the background .

.row {
        background-image: url(image.jpg);
        background-color: #c7b39b;
    }
  • Related