gpt4 book ai didi

html - Html 的 anchor 标记

转载 作者:可可西里 更新时间:2023-11-01 12:49:20 24 4
gpt4 key购买 nike

我在 html-email 中编码。有一个 <td>使用内联 CSS 代码。我必须做些什么才能在整个 <td> 上附加 anchor 标记.请告诉我该怎么做。我尝试了很多选项,但这些都无效。

<td valign="top"  width="204" class="leftColumnContent" mc:edit="left_column_content" align="center" bgcolor="#dee0e2" style="border-left:6px solid #FFF; border-top:5px solid #FFF;"">
<div align="center" style=" margin-top:10px;">
<img src="" width="119" height="199" style="max-width:180px;" mc:label="image" />
</div>
<p style=" margin-left:20px; width:80%; font-family:Arial, Helvetica, sans-serif; font-size:14px;"> <strong>Text here </strong><br />
<br />
text here</p>
<div style="width:80%; margin-top:10px; margin-left:20px; margin-bottom:15px;">
<div align="left" style="float:left;"><strong> read more</strong></div>
<div align="right">
<img align="none" height="20" id="headerImage2" mc:allowdesigner="" mc:allowtext="" mc:label="header_image" src=".." style="max-width: 55px; width: 55px; height: 23px;" width="55" /></div>
</div>
</td>

最佳答案

你不能有 <a ...><td>...</td></a> , 按照 HTML 规则。你可以反过来嵌套它们,<td><a ...>...</a></td> .如果您需要使整个单元格可点击,则需要设置 a 的样式。元素,使其占据整个单元格。这样做的方式取决于上下文,但如果 td元素具有固定尺寸,然后在 a 上设置以下内容里面的元素:

display: block; height: 100%;

关于html - Html 的 anchor 标记 <TD>,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18948811/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com