nwolf1151 nwolf1151 - 20 days ago 5
CSS Question

Why is my image not following the divs class?

I'm very new to html, here is my code:



.social-media {
height: 100px;
width: 100px;
border-radius: 25px;
}

<div class="social-media">
<a href="https://twitter.com/mytwitter" target="_blank">
<img src="http://icons.iconarchive.com/icons/limav/flat-gradient-social/256/Twitter-icon.png" alt="my twitter">
</a>
</div>





the twitter image is not changing from the css

Answer

Try this:

  .social-media img {
     height: 100px;
     width: 100px;
     border-radius: 25px;
  }