1
<input name="" onclick='copyToClipBoard()' type="button" value=" 复制本贴地址,传给QQ/MSN上的好友 ">
2![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
3
<script language="javascript">
4
function copyToClipBoard(){
5
var clipBoardContent="";
6
clipBoardContent+="要復制的數据";
7
clipBoardContent+="\n";
8
clipBoardContent+="http://www.foxconn.com";
9
window.clipboardData.setData("Text",clipBoardContent);
10
alert("复制成功,请粘贴到你的QQ/MSN上推荐给你的好友");
11
}
12
</script>
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
2
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
3
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
4
![](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedBlockStart.gif)
5
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
6
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
7
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
8
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
9
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
10
![](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
11
![](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedBlockEnd.gif)
12
![](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)