Html 使用vbscript将图像元素添加到td
有人知道如何使用vbscript在td元素上添加图像吗? 我需要添加一个“img”元素,而不是背景图像,它必须是vbscriptHtml 使用vbscript将图像元素添加到td,html,vbscript,Html,Vbscript,有人知道如何使用vbscript在td元素上添加图像吗? 我需要添加一个“img”元素,而不是背景图像,它必须是vbscript <script type="text/vbscript"> function onload() '//Add Image to td1 end function <script> <table> <tr> <td id="td1"></td> </tr> </table>
<script type="text/vbscript">
function onload()
'//Add Image to td1
end function
<script>
<table>
<tr>
<td id="td1"></td>
</tr>
</table>
函数onload()
'//将图像添加到td1
端函数
有人能帮我吗
提前感谢。您只需使用DOM即可完成此操作,就像在JavaScript中一样
Function onload()
Dim img
Set img = document.createElement("img")
img.src = "http://www.google.com/intl/en_ALL/images/logo.gif"
document.getElementById("td1").appendChild img
End Function