0

I copied the exact code from w3school for the mask-image css property but it does not work. I'm getting a blank result. It's crazy. What am I missing?

.mask1 {
  -webkit-mask-image: url(https://www.w3schools.com/css/w3logo.png);
  mask-image: url(https://www.w3schools.com/css/w3logo.png);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;    
}
<div class="mask1">
<img src="http://www.spab-rice.com/spabrice/wp-content/uploads/2016/10/17a-free-wordpress.jpg" alt="Cinque Terre" width="600" height="400">
</div>
Benmay
  • 347
  • 1
  • 15
  • 2
    You are linking to an image on w3schools and because your website isn't hosted on W3 schools website, it's giving you a CORS error. See https://stackoverflow.com/questions/31276220/cors-header-access-control-allow-origin-missing – Adam Sep 26 '22 at 15:09

0 Answers0