找回密码
 注册
搜索
热搜: 回贴
  • 前程无忧官网首页 有什么好的平台可以
  • 最新的销售平台 互联网营销的平台有哪
  • 制作网页的基本流程 网页制作和网页设
  • 【帝国CMS】输出带序号的列表(数字排
  • 网站建设公司 三一,中联,极东泵车的
  • 织梦 建站 织梦网站模版后台怎么更改
  • 云服务官网 哪些网站有免费的简历模板
  • 如何建网站要什么条件 建网站要用什么
  • 吉林市移动公司电话 吉林省退休人员网
  • 设计类毕业论文 网站设计与实现毕业论
查看: 11662|回复: 1

邮箱地址转换工具

[复制链接]
发表于 2009-11-24 03:00:21 | 显示全部楼层 |阅读模式 IP:江苏扬州
<!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-Type" content="text/html; charset=gb2312" />
<title>邮箱地址转换工具</title>
<style type="text/css">
<!--
body {
margin-left: 6px;
margin-top: 6px;
margin-right: 6px;
margin-bottom: 6px;
line-height:20px;
}
.STYLE1 {color: #FF0000}
-->
</style>
<script language="JavaScript" type="text/javascript">
//剪贴板
function CopyToClipboard(meintext)
{
    if (window.clipboardData)
    {
        // the IE-manier
        window.clipboardData.setData("Text", meintext);
    }
    else if (window.netscape)
    {
        // dit is belangrijk maar staat nergens duidelijk vermeld:
        // you have to sign the code to enable this, or see notes below
        netscape.security.PrivilegeManager.enablePrivilege('UniversalXPConnect');
         
        // maak een interface naar het clipboard
        var clip = Components.classes['@mozilla.org/widget/clipboard;1']
                        .createInstance(Components.interfaces.nsIClipboard);
        if (!clip) return;
        //alert(clip);
        // maak een transferable
        var trans = Components.classes['@mozilla.org/widget/transferable;1']
                        .createInstance(Components.interfaces.nsITransferable);
        if (!trans) return;
           
        // specificeer wat voor soort data we op willen halen; text in dit geval
        trans.addDataFlavor('text/unicode');
           
        // om de data uit de transferable te halen hebben we 2 nieuwe objecten
        // nodig om het in op te slaan
        var str = new Object();
        var len = new Object();
        var str = Components.classes["@mozilla.org/supports-string;1"]
                        .createInstance(Components.interfaces.nsISupportsString);
        var copytext=meintext;
        str.data=copytext;
        trans.setTransferData("text/unicode",str,copytext.length*2);
        var clipid=Components.interfaces.nsIClipboard;
        if (!clip) return false;
        clip.setData(trans,null,clipid.kGlobalClipboard);
    }
    else
    {
        return false;
    }
alert("复制成功,请Ctrl+V粘贴到收件人即可!");
    return false;
}
</script>
</head>
<body>

<%
function HTMLEncodesend(fString)
   ' fString = replace(fString, ">", "&gt;")
    'fString = replace(fString, "<", "&lt;")
   fString = Replace(fString, CHR(13), "")
   fString = Replace(fString, CHR(10), ",")
    HTMLEncode = fString
end function
dim aaaa,klist
emaillist=""
if request("action")="send" then
content=LCase(request.form("content"))
content=HTMLEncodesend(content)
sendemail=split(content,",")
'response.write sendemail(112)&"<br>"
klist=0
for i=0 to UBound(sendemail,1)
aaaa=trim(sendemail(i))
if aaaa<>"" then
if   chkEmail(aaaa) then
'else
emaillist=emaillist&aaaa&","
klist=klist+1
end if
else
exit for
end if
next
b=len(emaillist)
emaillist=left(emaillist,(b-1))
%>
<div style="width:480px;margin-bottom:16px;">
<textarea name="contentlist" cols="120" rows="5" onclick="CopyToClipboard('<%=emaillist%>')"><%response.write emaillist%></textarea>
</div>
将上面的邮件地址拷到 收件人即可!
<%
response.write "共转换有<font color=red>"&klist&"个</font>邮件"
else
end if
'邮箱验证过滤
function chkEmail(email)
      on error resume next
      dim i,l,pos1,pos2
      chkEmail=true
      if isnull(email) then chkEmail=false:exit function
      pos1= instr(email,"@")
      pos2=instrRev(email,".")
      if not(pos1>0) or not (pos2>0) or pos1>pos2 then            
         chkEmail=false
      end if
      if err.number<>0 then err.clear
end function

%>
<span class="STYLE1">最后面如果有逗号请去掉</span>
<form action="?action=send" method="post">
<p>邮件地址转换工具<br />
    <textarea name="content" cols="30" rows="16"></textarea>
限30个转换</p>
<p>
    <input type="submit" name="Submit" value="转换提交">
</p>
</form>
</body>
</html>
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|小黑屋|最新主题|手机版|微赢网络技术论坛 ( 苏ICP备08020429号 )

GMT+8, 2024-9-30 03:20 , Processed in 0.205542 second(s), 12 queries , Gzip On, MemCache On.

Powered by Discuz! X3.5

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表