Browser does not open HTML with CSS [closed]

-3
<html>
    <head>
    <style>
        body{
            margin: 0;
            padding: 0;
        }    
        #box1{
            height: 100vh;
            width: 100%;
            background-image: url(i1.jpg);
            background-size: cover;
            display: table;
            background-attachment: fixed;
        }
        #box2{
            height: 100vh;
            width: 100%;
            background-image: url(i2.jpg);
            background-size: cover;
            display: table;
            background-attachment: fixed;
        }
        #box3{
            height: 100vh;
            width: 100%;
            background-image: url(i3.jpg);
            background-size: cover;
            display: table;
            background-attachment: fixed;
        }
        h1{
            font-family: arial black;
            font-size: 50px;
            color:white;
            margin: 0px;
            text-align: center;
            display: table-cell;
            vertical-align: middle;
        }
    </style>
    </head>
    <body>
        <div id="box1">
            <h1>DAFT CREATION</h1>
        </div>
        <div id="box2">
            <h1>DAFT CREATION</h1>
        </div>
        <div id="box3">
            <h1>DAFT CREATION</h1>
        </div>
    </body>
</html>
    
asked by anonymous 21.11.2018 / 20:22

2 answers

4

It's because the css of your h1 contains the line: color:white .

So the text is white.

    
21.11.2018 / 20:32
0

Hello, you have defined the color of your H1 as white in CSS. There is nothing wrong when I run the page, the texts are displayed but if your background is also white you will not be able to see it at all.

    
21.11.2018 / 20:39