如何使用CSS的content
属性替换文本?
还有,如果你知道如何修复它,不必担心.fab
或Font Awesome。并且如果你能够修复JavaScript问题,那就太好了。
要在HTML中使用Font Awesome,请输入
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css" integrity="sha384-B4dIYHKNBt8Bc12p+WXckhzcICo0wtJAoU8YZTY5qE0Id1GSseTk6S+L3BlXeVIU" crossorigin="anonymous">
在您的头部标签中。
.sell {
margin: -20px auto;
width: 300px;
height: 30px;
background-color: #FDFEFE;
border: 2px solid #FDFEFE;
border-radius: 5px;
}
.styff {
font-size: 20px;
padding: 5px;
position: relative;
text-align: center;
margin: 0 auto;
}
.styff:hover:after {
font-size: 20px;
padding: 5px;
font-family: Font Awesome 5 Free;
position: relative;
text-align: center;
margin: 0 auto;
content: "This is currently not available in the App Store \f370";
}
.fab {
color: #29B6F6;
}
<div class="sell">
<p class="styff">Buy now in the App Store <i class="fab fa-app-store-ios fa-lg"></i></p>
</div>