<!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd">
<html>
<head>
<meta http-equiv="content-language" content="zh-cn">
<meta name="author" content="forfor">
<title> Test Document </title>
<script type="text/javascript">
<!--
function runSave(){
if (saveImg.location != "about:blank")window.saveImg.document.execCommand("SaveAs");
}
function saveImgAs(url){
if(window.saveImg && url)window.saveImg.location=url;
}
//-->
</script>
</head>
<body>
<img src="http://www.52hai.com/2005/smile/07.gif">
<a href="#" οnclick="saveImgAs('http://www.52hai.com/2005/smile/07.gif')">1</a><br>
<img src="http://www.52hai.com/2005/smile/06.gif">
<a href="#" οnclick="saveImgAs('http://www.52hai.com/2005/smile/06.gif')">1</a>
<iframe src="about:blank" name="saveImg" οnlοad="runSave()" style="display:none;"></iframe>
</body>
</html>
通过点连接来保存图片
最新推荐文章于 2024-09-03 09:58:06 发布