Id selector


#1


Hello,
I have a little problem with CSS, i can't go trough the 9th part!


https://www.codecademy.com/en/courses/make-a-website/lessons/closer-look-css/exercises/id-selectors


"Did you give the #footer selector a font-size property of 0.75rem in main.css?" they said. But i did right?


<!DOCTYPE html>
<html>
<head>
    <title>Sprout</title>
    <link rel="stylesheet" type="text/css" href="main.css"/>
</head>
<body>
    <h1>Mystwood Publishers Ltd.</h1>
    <div class="hero">
        <h2>Sprout.</h2>
        <p>A book by J. Daniel Bedford</p>
    
    

</div>
  <p id="footer">&copy; Mystwood Publishers Limited</p>
 </body>
</html>

body {
    height: 100%;
    margin: 0;
    text-align: center;
    width: 100%;
}


h1 {
  color:rgb(121,149,117);
    font-size: 32px;
  font-family: Palatino, 'Palatino Linotype', serif;
}

h2 {
    font-size: 56px;
}


.hero {
  font-family: 'Trebuchet MS', Helvetica, sans-serif;
    padding: 250px 0;
  color: #ffffff ;
    margin: 30px;
  background-image : url(https://s3.amazonaws.com/codecademy-content/projects/make-a-website/lesson-2/bg.jpg) ;
  
}


p {
font-size: 2rem;
  
}

.hero a {
   font-size: 1,25em;
    color: #00FFAA;

    text-decoration: none;
}

#footer { 
  font-size : 0,75rem;
}


#2

Post your main.css code


#3

You're using a comma instead of a dot, it should work with 0.75rem.

Here's a codepen with examples:


#4

thank you very much :slight_smile:


#5

This topic was automatically closed after 7 days. New replies are no longer allowed.