我有点困惑.我正在改造Square Space网站.我正在使用他们的beta'开发者'模式; 到目前为止似乎只允许CSS文件的来源,一切都在他们的' 块 '或.页 /.块.没有.html或.php文件可以在任何地方找到.
所以我被困在他们的"代码注入区域" - 以及页脚.我设置了页脚内容,但除了主页之外,页脚应该显示在任何地方.我想知道你是否有人知道一种编写内联JS和/或CSS的方法,只能在主页上隐藏页脚; 或通过主页URL?
<center>
<div>
<a class="footer" href="https://coolguys.squarespace.com/terms/">FAQ</a> •
<a class="footer" href="https://coolguys.squarespace.com/green/">GREEN</a> •
<a class="footer" href="https://coolguys.squarespace.com/wholesale/">WHOLESALE</a> •
<a class="footer" href="https://manbearpigs.squarespace.com/links/">LINKS</a>
<br>
<span>Hello World</span>
</div>
Run Code Online (Sandbox Code Playgroud)
使用纯CSS执行此操作将是最优选的.
我找到了这个:
body.page-id-777 td#footer {
display:none;
}
Run Code Online (Sandbox Code Playgroud)
但不确定页面URL或等等; 可以转换为页面ID.