点击页面的一个链接    即可探出outlook 分别在主题和内容处显示页面的title和url链接 。 谢谢了

解决方案 »

  1.   

    <html>
    <head><title>MailTo</title></head>
    <body>
    <a href="http://www.163.com" onclick="MailTo(this)">aa</a>
    <script>
    function MailTo(a)
    {  
      link=a.href;
      //更改连接属性
      a.href="mailto:[email protected]?subject="+document.title+"&body="+link;
    }
    </script>
    </body>
    </html>
      

  2.   

    “&”  请问我的link里面有这个字符 , 为什么在“&”后面的link 其他部分不显示?
    谢谢了 
      

  3.   

    加个encodeURIComponent!
    L@_@K
    <!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>
        <title>Good Luck</title>
        <meta name="generator" content="editplus" />
        <meta name="author" content="Gao YiXiang" />
        <meta name="email" content="[email protected]" />
        <meta name="keywords" content="javascript dhtml dom" />
        <meta name="description" content="I love web development." />
    </head>
    <body>
        <a href="http://www.126.com?s=good&a=luck" onclick="contactUs(this)">Contact 
        Us</a>
        <script type="text/javascript">
        <!--
    function contactUs(link)
    {
        link.href = "mailto:[email protected]?subject=" + document.title + "&body=" + encodeURIComponent(link.href);
        //alert(link.href);
    }
        //-->
        </script>
    </body>
    </html>