html - 测试时页脚中显示的正文链接,但代码中没有
问题描述
对不起我的天真我对网络开发很陌生,必须为一个 uni 项目创建这个。我遇到的问题是我有一个图像缩略图网格,该网格链接到单独页面上的完整版本,网格中的最后一个图像有一个链接,该链接显示并将内容推出页脚并检查页面上的元素说它在页脚 div 中的链接,但在代码中它不存在。任何帮助,将不胜感激。
.grid {
margin-left: 15%;
margin-right: 15%;
margin-top: 10px;
margin-bottom: 10px;
overflow: hidden;
}
.square {
display: inline-block;
float: left;
position: relative;
width: 30%;
padding-bottom: 30%;
/* = width for a 1:1 aspect ratio */
margin: 1.66%;
overflow: hidden;
}
.content {
position: absolute;
height: 100%;
width: 100%;
padding: 0%;
}
/* For responsive images */
.content .rs {
width: auto;
height: auto;
max-height: 100%;
max-width: 100%;
}
.footer {
height: 45px;
width: 100%;
background-color: white;
overflow: auto;
position: -webkit-sticky;
position: sticky;
z-index: 1;
bottom: 0;
list-style-type: none;
overflow: hidden;
padding-bottom: 5px;
padding-top: 5px;
overflow: hidden;
}
.footer a {
display: inline;
color: black;
text-align: center;
padding-top: 5px;
padding-bottom: 10px;
text-decoration: none;
font-family: 'myntieregular';
src: url('myntie-regular-webfont.woff') format('woff');
font-weight: normal;
font-style: normal;
font-size: 45px;
float: left;
text-decoration: none;
width: 33%;
text-align: center;
border-top-style: solid;
border-color: #c7c7c7;
border-width: 2px 0px;
}
<div class="grid">
<div class="square">
<div class="content">
<a href="Gallery\DSCF1629.html"><img class="rs" src="Images\Thumbnails\DSCF1629_Thumbnail.png" />
</div>
</div>
<div class="square">
<div class="content">
<a href="Gallery\DSCF1425.html"><img class="rs" src="Images\Thumbnails\DSCF1425_Thumbnail.png" />
</div>
</div>
<div class="square">
<div class="content">
<a href="Gallery\DSCF1723.html"><img class="rs" src="Images\Thumbnails\DSCF1723_Thumbnail.png" />
</div>
</div>
</div>
<div class="footer">
<a href="link" target="_blank"><img src="Image" alt="Instagram" style="width:30px;height:30px;"></a>
<a href="link" target="_blank"><img src="Image" alt="Email" style="width:30px;height:30px;"></a>
<a href="link/" target="_blank"><img src="Image" alt="linkedin" style="width:30px;height:30px;"></a>
</div>
解决方案
忘记关闭div中的<a>
标签。"grid"
很难看到,因为它太偏右了。
推荐阅读
- python - 如何使用 python 从 NAT 内部网络获取我的公共 IPV4 地址
- timeout - 超时 - 谷歌计算引擎
- laravel-lighthouse - 灯塔嵌套删除突变不起作用
- node.js - 安装ejs时NodeJS意外的严格模式保留字“let”(不是我的代码)
- css - 如何避免 CSS 规则 * {} trump .a .b {}?
- powerbi - Power BI - 根据条形图中的选择过滤表
- django - django - 值错误:
在可以使用这种多对多关系之前,需要为字段“id”设置一个值 - performance - 在 Jmeter 中以定期间隔暂停所有线程特定持续时间
- android - 从 LiveData(房间数据库)填充微调器
- sql - 对重复的列值而不是其他列运行总计