87,909
社区成员
发帖
与我相关
我的任务
分享
<script type="text/javascript">
//<![CDATA[
$(function(){
$('#table1 img').each(function(i,o){
var $o=$(this);$o.attr('src',$o.attr('src').replace(/images\/dialog\/query\/detail\/.*\//g,'images\/dialog\/query\/detail\/散点图\/'));
});
});
//]]>
</script>
<script type="text/javascript">
//<![CDATA[
$(function(){
$('#table1 img').each(function(i,o){
var $o=$(this);$o.attr('src',$o.attr('src').replace(/.*\//g,'散点图\/'));
});
});
//]]>
</script>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>test</title>
<script src="jquery-1.3.2.js"></script>
<script>
$(function(){
$("img").each(function(){
var src = $(this).attr("src");
var temp_src = "散点图" + src.substring(src.length-6,src.length);
$(this).attr("src",temp_src);
});
});
</script>
</head>
<body>
<table id="table1" cellpadding="5" cellspacing="5">
<tr>
<td>
<img alt="" src="柱形图/a.png" />
</td>
<td>
<img alt="" src="条形图/b.png" />
</td>
</tr>
<tr>
<td>
<img alt="" src="雷达图/c.png" />
</td>
<td>
<img alt="" src="饼形图/d.png" />
</td>
</tr>
</table>
</body>
</html>