html - 如何从 Blogger 中的特定页面删除侧边栏

标签 html css blogger

<b:if cond='data:blog.url == "#url"'>
<style>
.main-inner .columns {
padding-left: 0px !important;
padding-right: 0px !important;
}
.main-inner .fauxcolumn-center-outer {
left: 0px !important;
right: 0px !important;
}
.main-inner .fauxcolumn-left-outer, .main-inner .fauxcolumn-right-outer, .main-inner .column-left-outer, .main-inner .column-right-outer {
display: none !important;
}
</style>
</b:if>

上面的代码删除了 Blogger 中的所有侧边栏,但我想删除特定页面的侧边栏。

任何解决方案??

最佳答案

如果侧边栏内容占用大量资源,减少页面加载时间的更有效方法是在这些页面上将其完全删除,而不是“隐藏”它。

<b:if cond='data:blog.url != "#url"'>
<!--SIDEBAR HTML CODE-->
</b:if>

关于html - 如何从 Blogger 中的特定页面删除侧边栏,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48126257/

相关文章:

javascript - 如何检查 Canvas 上是否绘制了某些东西

android - 通过 Web 服务检索博客文章?

javascript - 具有 2 个 Y 轴的莫里斯折线图

html - 导航栏在大屏幕中保持在我自己的宽度中心

css - 在 React 中缓和过渡

css - capybara /CSS : How to find an input field by label AND value?

jquery - 使用jquery在排序中隐藏所有内容

javascript - prettyPrint() 不会在页面加载时被调用

html - 在 Chromium 和 Firefox/Opera 中查看时,Blogger.com 上的 CSS 行为/对齐方式不同

html - 溢出 - 隐藏滚动条并禁用滚动但不剪辑元素