【问题标题】:Cannot change the font size of div class="entry-content" in WordPress无法在 WordPress 中更改 div class="entry-content" 的字体大小
【发布时间】:2020-01-30 14:09:07
【问题描述】:

我似乎无法在我的 WordPress 网站中更改 div class="entry-content" 的字体大小。我正在使用 Google Fonts 插件来添加 CSS 选择器,但它似乎并没有改变太大的帖子的字体。我确实设法使用 Google 字体插件(h1.entry-title,p.form-submit)更改了其他页面和帖子的字体,但它不适用于 div 类。

【问题讨论】:

标签: css wordpress


【解决方案1】:

这是更改任何内容的代码,例如我更改了颜色、字体大小和填充

article .content-wrap-inner .entry-content p {
    font-size: 24px;
    padding: 20px;
    color: #000;
    background-color: rgba(0,0,0,0);
}

【讨论】:

  • 感谢您的代码。现在我已经固定了字体大小,我只剩下白色的块了,而且线条之间有一个相对巨大的间隙。请重新访问我的网站lgediot.000webhostapp.com/monthly-progress-report/staff-members 并查看。
  • 您想减小白块间隙对吗?我已经更新了我的代码使用'margin-bottom:20px;'为此。
  • 我其实不想有白块。如何去除白块?此外,线条之间存在巨大的差距,令人讨厌。
  • 确定添加这个css属性'background-color: rgba(0,0,0,0);'
  • 什么都不做。白色背景仍然存在。
【解决方案2】:

试试这个:

.entry-content p {
  font-size: 20px;
}

这将针对.entry-content 类中的<p>。

【讨论】:

猜你喜欢
  • 2019-07-10
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2018-08-15
  • 1970-01-01
  • 2016-06-05
  • 1970-01-01
相关资源
最近更新 更多