yannis kls2012 可能是footer元素冲突的问题,可以自己改一下~ 因为这里的footer泛指的太广, footer{ position: relative; } footer.你的冲突元素 { position: unset; }//与鲸鱼动画的footer>position冲突
mrblack 总结,在后台-外观-自定义页脚中添加以下代码即可 <div id="flyfish" class="fly-fish" height="200"></div> <script src="https://discuss.flarum.org.cn/fish.js"></script>
Tim 黑夜模式食用更佳,记得修改对应文字即可 页脚格式: <!– 页脚 –> <footer> <div class=“site-footer”> <div style=“color: rgb(137, 137, 140);font-size:0.9em;” class=“footer-container rm-link-color”> <p> <!– 加载时间 –> <script> var start_time = new Date(); var end_time = ""; var loadt = setInterval(function () { if (document.readyState == “complete”) { showLoadTime(); } }, 500) function showLoadTime() { end_time = new Date(); loadtime_span.innerHTML = "T " + (end_time.getTime() - start_time.getTime()) + " ms"; clearInterval(loadt); } </script> <!-- IP --> <span id="ip_span" align=center></span> <script src="https://pv.sohu.com/cityjson?ie=utf-8"></script> <script type="text/javascript"> ip_span.innerHTML = returnCitySN["cname"] + " " + returnCitySN["cip"]; </script> <span class="mx-2">|</span> <span id="loadtime_span">T</span> <span class="mx-2">|</span> <a id="stats" href="https://stats.uptimerobot.com/QAL8xc6m8y" target="_blank"></a> </p> <p> <a id="prot_span" href="https://discuss.flarum.org.cn/docs/protocol.html"></a> <span class="mx-2">|</span> <a id="rept_span" href="mailto:flarumcn@qq.com"></a> <span class="mx-2">|</span> <span id="ver_span"></span> <p id="right_span"></p> </p> <!-- 声明 --> <script type="text/javascript"> var site_version = "1.1.1-211101"; var lang = document.getElementsByTagName("html"); var userLang = lang[0].getAttribute("lang"); if (userLang.includes("zh")) { stats.innerHTML = "状态"; prot_span.innerHTML = "社区规范"; rept_span.innerHTML = "违法和不良信息举报"; ver_span.innerHTML = "版本 " + site_version; right_span.innerHTML = "本站独立于 Flarum 基金会运行。<a href=\"https://flarum.org/verified-communities\"><i class=\"fas fa-info-circle\"></i> 了解官方认证社区</a>"; } else { stats.innerHTML = "Status"; prot_span.innerHTML = "Protocol"; rept_span.innerHTML = "Report"; ver_span.innerHTML = "Version " + site_version; right_span.innerHTML = "This site operates independently of the Flarum Foundation. Read more about <a href=\"https://flarum.org/verified-communities\"><i class=\"fas fa-info-circle\"></i> verified communities</a>."; } </script> </div> </div> <div id="flyfish" class="fly-fish" height="200"></div> </footer> <script src=“/fish.js”></script> 自定义css: .site-footer { margin:0; /margin-top:64px;/ padding-top:30px; padding-bottom:30px; color:hsla(0,0%,100%,.9); box-sizing:inherit; text-align:center; font-size:1em } @media (max-width:991px){ .site-footer { padding-top:0px; } } .site-footer p { margin:0 } .rm-link-color > p > a { text-decoration:none; color:#89898c } .rm-link-color > p > a:hover { text-decoration:underline } .fly-fish{ z-index: -1; line-height: 0px; height: 350px; } footer{ position: relative; } .site-footer{ position: absolute; width: 100%; top: calc(100% / 4 * 3); transform: translateY(calc(-50% + 10%)); padding: 0; } .App{ padding-bottom: 0; } @media (max-width: 767px){ .App{ padding-bottom: 0; } .App-content { padding-bottom: 0; } }
sunjie7777 烟柳拂风 我对fish.js稍稍做了修改,使他支持前景色和背景色的自定义。fish2.txt11kB 在css设置中添加 .fly-fish{ z-index: -1; line-height: 0px; height: 350px; /前景色/ color:#33ccff; /背景色/ background-color:#F5FFFA; } 就是蓝色的大海。 你也可以自己配一下颜色。