日期:2014-05-17  浏览次数:20779 次

图片链接为什么会失效?
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<form method="POST" name="myform">
 <table cellpadding="0" cellspacing="1" class="table_foot">
  <tr>
  <td width='20%' valign='top' class='td_ad'><a href='http://www.xmmycj.com.cn'>this done</a></td>
  <td width='20%' valign='top' class='td_ad'><a href='http://www.zisha123.com'><input type='image' src='image/ad4.png' align='middle' height='60'></a></td>
  </tr>
 </table>
</form>
</body>
</html>

以上代码运行后点图片链接不跳转(重载本页),而点文字链接则正常跳转。如果去掉form标签一切正常,但还存在其它表单的POST提交,不可能去掉form。

为什么会这样?怎样解决?

------解决方案--------------------
<td width='20%' valign='top' class='td_ad'><a href='http://www.zisha123.com'><img src='image/ad4.png' align='middle' height='60'></a></td>
换成img标签
------解决方案--------------------
路径不对吧,
<input type='image' src='image/ad4.png' align='middle' height='60'>
是会提交表单的
------解决方案--------------------
<input type='image' />
其实就是一个图片状的 submit