V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
jiaowobaba
V2EX  ›  C#

基于 C#的短信接口调用示例代码模板

  •  1
     
  •   jiaowobaba · 2016-09-26 17:59:37 +08:00 · 1770 次点击
    这是一个创建于 2740 天前的主题,其中的信息可能已经有所发展或是发生改变。

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Net.Security;
    using System.Security.Cryptography.X509Certificates;
    using System.Net;
    using System.IO;
    using System.IO.Compression;
    using System.Text.RegularExpressions; using System.Security.Cryptography; using System.Web; public class Test { private static readonly string DefaultUserAgent = "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.2; SV1; .NET CLR 1.1.4322; .NET CLR 2.0.50727)";

        private static bool CheckValidationResult(object sender, X509Certificate certificate, X509Chain chain, SslPolicyErrors errors)  
        {  
            return true; //总是接受     
        }  
     static void Main(string[] args)  
        {  
            DateTime dt = DateTime.Now; 
            string mttime = dt.ToString("yyyyMMddHHmmss");
            string pwd1 = "*************"+mttime;
      string pwd = GetMD5(pwd1)
            string content = " [阅信短信平台] 验证码 888888 ,打死也不能告诉别人哦。";
            string url = "http://IP/端口号";
    
    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3243 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 12:14 · PVG 20:14 · LAX 05:14 · JFK 08:14
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.