【问题标题】:Float right is not working with my Wordpress Mantra theme向右浮动不适用于我的 Wordpress Mantra 主题
【发布时间】:2016-12-08 06:40:19
【问题描述】:

我需要在页面的右上角放置一个表格,并在表格周围环绕文字。我使用了以下代码。

.floater {
margin: 5px;
float: right;
}
.floater td {
padding: 2px;
border: 1px solid black;
}

<table class="floater">
*--- table---*
</table>
<p>text</p>

这里是 jsfiddle:http://jsfiddle.net/es7t7xyo/ 它适用于所有编辑器,并且在我的网站更新时无法正常工作。我正在使用 Wordpress Mantra 主题。

【问题讨论】:

  • 然后发布你的代码,这不起作用。
  • 以上我发布的内容无法在浏览器中使用我的网站。在编辑器或 jsfiddle 中运行相同的代码时,它工作正常并且在实际的网站页面中工作。那是我的问题。
  • 为您的表格分配特定宽度,它将起作用

标签: css wordpress html-table css-float


【解决方案1】:

您应该定义表格的宽度,例如:

.floater {
    margin: 5px;
    float: right;
    width: 200px;
}
.floater td {
    padding: 2px;
    border: 1px solid black;
}
<table class="floater">
    <tr><td>11</td><td>12</td><td>13</td></tr>
    <tr><td>21</td><td>22</td><td>23</td></tr>
    <tr><td>31</td><td>32</td><td>33</td></tr>
</table>
<p>Objectively matrix extensive manufactured products without cost effective ROI. Conveniently seize competitive expertise vis-a-vis standardized action items. Distinctively administrate scalable leadership after world-class process improvements.</p>
<p>Progressively utilize adaptive deliverables before open-source manufactured products. Appropriately transition innovative metrics for optimal methodologies. Assertively customize alternative customer service without client-focused web-readiness.</p>

【讨论】:

猜你喜欢
  • 2018-08-04
  • 2015-10-01
  • 2022-01-18
  • 2012-08-15
  • 1970-01-01
  • 1970-01-01
  • 2019-12-05
  • 2019-03-05
  • 2021-01-16
相关资源
最近更新 更多