Style those divs - error


#1



My CSS code is as below:
div {
display: inline-block;
margin-left: 5px;
height: 100px;
width: 100px;
border-radius: 100%;
border:2px solid black;
}

i still the same error as before where the error message reads " Make sure your

s are 100 pixels high( if your height looks correct,make sure your border-radius is 100% ,not100pxl)


Replace this line with your code.

Continuing the discussion from Style those divs!: Can't find my mistake:


#2

Did you ensure your browser zoom is set at the right level? And your html code is correct? Looks fine to me, try a different browser


#3

Thanks for the quick response .

Tried using Google Chrome too; its still gives the same error .

If i need to type this CTRL 0 where should this be typed in HTML tab or the CSS tab and where inside the tab should it be filled after the syntax's?

Kindly advice .

Thank you


#4

ctrl + 0 shouldn't be typed anywhere, it will change your browser zoom level

Please post your full html + css code


#5

HTML code :

<!DOCTYPE html>
<html>
    <head>
        <link type="text/css" rel="stylesheet" href="stylesheet.css"/>
        <title>My Social Network</title>
    </head>
    <body>
        <div style=" width:50;height:50px;background-color:green"></div>
        <div style=" width:50;height:50px;background-color:black"></div>
        <div style=" width:50;height:50px;background-color:violet"></div>
        
    </body>
</html>

CSS code:
div {
display: inline-block;
margin-left: 5px;
height: 100px;
width: 100px;
border-radius: 100%;
border:2px solid black;
}


#6

using the style attribute will overwrite css in the external stylesheet (stylesheet.css)


#7

Please suggest an alternative to style i can use


#8

When the style aspect was removed from the DIV tag the CSS was executed . I still do not know if the amended HTML code is right because there are three circles with a solid outline as its boundry but there is no colour to fill the inside


Oops, try again. Make sure your <div>s are 100 pixels high! (If your height looks correct, make sure your border-radius is 100%, not 100px!)
#9

you should have removed the width, height and background-color in the index.html, since it overwrites what you write in the stylesheet.css


#10

Really appreciate your kind assistance .

Thank you !


#11

If i copy your CSS it works fine. If i use my own writen CSS code the course give me a error message.


#12

#13

This topic is really old, if you need help, please make a new topic