在html li标签内编写html表是否是很好的验证

时间:2014-07-03 10:48:58

标签: html html-table html-lists

我已经编写了这段代码,想知道这是一个很好的解决方案,在table标签内有一个li因为我有2个表吗?而且我不想在桌子前面显示li子弹。

这是我的代码:

<ul id="widget_update">
    <li id="Fahrzeuge"><img src="arrow.png" alt="move" width="16" height="16" class="handle" />
        <table width="538" cellspacing="0" cellpadding="0" border="0" >
        <tr>
            <td id="fahrzeuge">

            </td>
        </tr>
    </table>
    </li>
    <li id="NEWS"><img src="arrow.png" alt="move" width="16" height="16" class="handle" />
        <table width="538" cellspacing="0" cellpadding="0" border="0">
        <tr>
            <td id="news">          
            </td>
        </tr>
    </table>
    </li>
    </ul>

1 个答案:

答案 0 :(得分:1)

在这种情况下你可以使用div来自动删除子弹,不需要css修复。 Fiddle

<div id="widget_update">
 <div id="Fahrzeuge"><img src="https://lh3.googleusercontent.com/-SWOcB8HK24k/AAAAAAAAAAI/AAAAAAAAAAA/idI3VNCg4KI/photo.jpg" alt="move" width="16" height="16" class="handle" />
    <table width="538" cellspacing="0" cellpadding="0" border="0" >
      <tr>
        <td id="fahrzeuge">

        </td>
    </tr>
  </table>
  </div>
<div id="NEWS"><img src="https://lh3.googleusercontent.com/-SWOcB8HK24k/AAAAAAAAAAI/AAAAAAAAAAA/idI3VNCg4KI/photo.jpg" alt="move" width="16" height="16" class="handle" />
    <table width="538" cellspacing="0" cellpadding="0" border="0">
    <tr>
        <td id="news">          
        </td>
    </tr>
</table>
</div>
</div>