另一张桌子内的表格被压扁

时间:2016-08-04 07:49:53

标签: html css

将一个表嵌套在另一个表中时遇到问题:

Squashed table

我希望内部表跨越外部表的整个宽度。这是生成的HTML:

    <table class="table table-bordered table-striped">

<tr><td align="center">4 laptops were not added because they lacked unique identifiers.</td></tr>  <tr><td align="center">2 laptops were not added because they already exist in the database: </td></tr><tr><td>
  <table><th>Hostname</th><th>Asset Tag</th><th>Serial</th>
      <tr>
      <td></td>
      <td></td>
      <td>4646466</td>
    </tr>
      <tr>
      <td></td>
      <td></td>
      <td>4646467</td>
    </tr>
    </table></td></tr>
  <tr><td align="center">2 laptops were added to the database: </td></tr><tr><td>
  <table><th>Hostname</th><th>Asset Tag</th><th>Serial</th>
      <tr>
      <td></td>
      <td></td>
      <td>4646468</td>
    </tr>
      <tr>
      <td></td>
      <td></td>
      <td>4646469</td>
    </tr>
    </table></td></tr>
</table>

2 个答案:

答案 0 :(得分:1)

看看

<?xml version="1.0" encoding="UTF-8"?>
<configuration>
    <system.webServer>
        <rewrite>
            <rules>
                <rule name="rule01" patternSyntax="Wildcard" stopProcessing="true">
                    <match url="http://www.somedomain.net/index.php?sid=73742&amp;lang=nl" />
                    <action type="Redirect" url="http://www.someotherdomain.net/survey/index.php?r=survey/index&amp;sid=73742&amp;lang=nl" appendQueryString="false" />
                    <serverVariables>
                    </serverVariables>
                </rule>
            </rules>
        </rewrite>
    </system.webServer>
</configuration>

答案 1 :(得分:1)

只需添加width属性

即可
width = '100%'

到内表。它会使它遍布包含单元格的宽度。

DEMO