求助大神,怎么给每张图片加链接啊?
html吧
全部回复
仅看楼主
level 2
tbsgsb 楼主
<div style="width: 100%; height: 500px;" data-title="">
<div class="next-balloon" style="width: 100%; height: 500px; left: 50%; margin-top: 0px; margin-bottom: 0px; margin-left: -50%; max-width: 100%; border: none; overflow: hidden; z-index: 2;">
<div class="next-balloon" style="width: 2000px; left: 50%; margin-left: -960px; max-width: 2000px; border: none;">
<div class="sc-hd-m-droplist" style="word-wrap: break-word; word-break: break-all; position: relative; width: 1920px; height: 500px; display: block; background-color: #ffffff;" data-title=""><a class="sc-hd-m-menu" style="text-indent: -9999px; left: 0px; top: 0px; width: 1920px; height: 500px; background: url('//sc01.alicdn.com/kf/H584f66130502487a9114f2573f776fbax/202171482/H584f66130502487a9114f2573f776fbax.jpg') no-repeat 50% 50%; border: 0px; padding: 0; display: block; right: auto;" title="">.</a>
<div class="sc-hd-m-menu" style="left: 1028px; top: 150px; width: 240px; height: 260px; display: block; border: none; padding: 0; background: none; right: auto;">
<div class="fkdmg_com sc-hd-m-droplist" style="height: 260px; position: relative; width: 240px; background: none transparent;">
<div class="sc-hd-ms-dp-trigger" style="width: 240px; background-image: url('//sc04.alicdn.com/kf/Ha02abc356b174b5daa7255b75f9e2b2fz/202171482/Ha02abc356b174b5daa7255b75f9e2b2fz.jpg'); position: relative; margin-top: 0px; margin: 0px; padding: 0px; float: none; left: 0px; z-index: 1; height: 260px;"> </div>
</div>
</div>
<div class="sc-hd-m-menu" style="left: 496px; top: 150px; width: 240px; height: 260px; display: block; border: none; padding: 0; background: none; right: auto;">
<div class="fkdmg_com sc-hd-m-droplist" style="height: 260px; position: relative; width: 240px; background: none transparent;">
<div class="sc-hd-ms-dp-trigger" style="width: 240px; background-image: url('//sc02.alicdn.com/kf/H4876c3ca6cc24d88bc58e8a30e493fc2G/202171482/H4876c3ca6cc24d88bc58e8a30e493fc2G.jpg'); position: relative; margin-top: 0px; margin: 0px; padding: 0px; float: none; left: 0px; z-index: 1; height: 260px;"> </div>
</div>
</div>
<div class="sc-hd-m-menu" style="left: 230px; top: 150px; width: 240px; height: 260px; display: block; border: none; padding: 0; background: none; right: auto;">
<div class="fkdmg_com sc-hd-m-droplist" style="height: 260px; position: relative; width: 240px; background: none transparent;">
<div class="sc-hd-ms-dp-trigger" style="width: 240px; background-image: url('//sc04.alicdn.com/kf/Hb5e4fcf8d6ed4d2eab46d8445a9c2681V/202171482/Hb5e4fcf8d6ed4d2eab46d8445a9c2681V.jpg'); position: relative; margin-top: 0px; margin: 0px; padding: 0px; float: none; left: 0px; z-index: 1; height: 260px;"> </div>
</div>
</div>
<div class="sc-hd-m-menu" style="left: 762px; top: 150px; width: 240px; height: 260px; display: block; border: none; padding: 0; background: none; right: auto;">
<div class="fkdmg_com sc-hd-m-droplist" style="height: 260px; position: relative; width: 240px; background: none transparent;">
<div class="sc-hd-ms-dp-trigger" style="width: 240px; background-image: url('//sc04.alicdn.com/kf/H7bcb083aec1b4809a3b3510e96b2d448S/202171482/H7bcb083aec1b4809a3b3510e96b2d448S.jpg'); position: relative; margin-top: 0px; margin: 0px; padding: 0px; float: none; left: 0px; z-index: 1; height: 260px;"> </div>
</div>
</div>
<div class="sc-hd-m-menu" style="left: 1294px; top: 150px; width: 240px; height: 260px; display: block; border: none; padding: 0; background: none; right: auto;">
<div class="fkdmg_com sc-hd-m-droplist" style="height: 260px; position: relative; width: 240px; background: none transparent;">
<div class="sc-hd-ms-dp-trigger" style="width: 240px; background-image: url('//sc02.alicdn.com/kf/H6ede78cef10f492281cf8d4452c87c8fd/202171482/H6ede78cef10f492281cf8d4452c87c8fd.jpg'); position: relative; margin-top: 0px; margin: 0px; padding: 0px; float: none; left: 0px; z-index: 1; height: 260px;"> </div>
</div>
</div>
<div class="sc-hd-m-menu" style="left: 1560px; top: 150px; width: 130px; height: 260px; display: block; border: none; padding: 0; background: none; right: auto;">
<div class="fkdmg_com sc-hd-m-droplist" style="height: 260px; position: relative; width: 130px; background: none transparent;">
<div class="sc-hd-ms-dp-trigger" style="width: 130px; background-image: url('//sc02.alicdn.com/kf/H61a3c86e457a472784e84a59a060ff92E/202171482/H61a3c86e457a472784e84a59a060ff92E.jpg'); position: relative; margin-top: 0px; margin: 0px; padding: 0px; float: none; left: 0px; z-index: 1; height: 260px;"> </div>
</div>
</div>
</div>
</div>
</div>
</div>
2022年06月23日 06点06分 1
level 8
建议重写
<div class="next-balloon"><!--MegaMenu容器-->
<div class="sc-hd-m-droplist"><!--MegaMenu本体,这个带背景图片-->
<a class="sc-hd-m-menu"><!--MegaMenu菜单项-->
<img src="菜单项图片地址,也可以写进a.sc-hd-m-menu里的背景图片">
<span class="sr-only" hidden>可选隐藏文字</span>
</a><!--更多菜单项略-->
</div>
</div>
2022年06月23日 06点06分 2
谢谢,主要我完全不会,现在这个就差加链接,但是我不知道应该插在哪里[泪]
2022年06月23日 08点06分
level 2
加个a不就好了
2022年06月24日 03点06分 3
我知道加a,但是不知道放在哪个位置,能跟我细说下吗[泪]
2022年06月30日 02点06分
@tbsgsb 等下午我看一下
2022年06月30日 03点06分
level 4
外面包个a就可以了要不然你把图片当li加背景也可以
2022年06月24日 04点06分 4
在具体哪个位置加,我是小白[泪]
2022年06月30日 03点06分
图片那个前面
2022年07月03日 04点07分
你div放图片的话就放div前面
2022年07月03日 04点07分
1