php - 无法点击 Href 链接
问题描述
我在我的网站上发现了一个问题,我无法单击 href 链接。
在我的离线测试中,它可以工作,但是当我上传到主机时,链接将不起作用。我在我的网站上包含了 html 和 css 编码。
这是我的CSS:
.footer-social-icon > a > i {
background: #2e93fa;
font-size: 14px;
color: #ffffff;
height: 40px;
width: 40px;
line-height: 40px;
font-weight: 500;
border-radius: 10px 10px 10px 0px;
margin-right: 10px;}
这是我的 HTML:
<div class="footer-social-icon">
<a href="https://www.facebook.com/myavinofficial/"><i class="fa fa-facebook" aria-hidden="true"></i></a>
<a href="#"><i class="fa fa-twitter" aria-hidden="true"></i></a>
<a href="https://instagram.com/myavinofficial?igshid=mt79av9pihaq"> <i class="fa fa-instagram" aria-hidden="true"></i></a>
<a href="https://www.youtube.com/channel/UCNtsL7TC0JfTiIjngA8dY9g"><i class="fa fa-youtube" aria-hidden="true"></i></a>
<a href="https://api.whatsapp.com/send?phone=6289631925737&text=Halo%2C%20MyAVin!%20Ada%20yang%20ingin%20saya%20tanyakan%20nih."><i class="fa fa-whatsapp" aria-hidden="true"></i></a>
</div>
请帮助我。谢谢
解决方案
该代码对我有用。也许您忘记添加 font-awesome 库。如果您没有链接,则无法显示任何信息。
<link href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-
awesome.min.css" rel="stylesheet" integrity="sha384-
wvfXpqpZZVQGK6TAh5PVlGOfQNHSoD2xbE+QkPxCAFlNEevoEH3Sl0sibVcOQVnN"
crossorigin="anonymous">
尝试将其添加到 html 文件的头部
推荐阅读
- sqlite - 嗨,我需要知道如何将大量文本插入 SQLite,因为我使用 Ionic 为一本书创建了一个应用程序
- binding - Svelte 中的 HTML 元素绑定顺序
- r - 使用 mle2 进行有误差的参数估计并进行预测
- optimization - CPLEX 等优化软件的局限性
- c - 使用嵌套 if 查找四个数字中最大的程序
- r - 我的数据框似乎有列名,但是当我尝试使用 lm() 函数并命名列时,r 说“找不到对象”
- c++ - 在 C++ 中修改“常量字符指针”
- python - python中的外推(炸弹热量计中的温度曲线)
- ruby-on-rails - 在 Rails 4 和 Rails 6 中工作的回形针替代品
- hybris - 如何确定 Hybris 扩展无法加载的原因