asp.net core 发送253短信

浪淘沙2周前后端15
<form method="post">
    <button type="submit" asp-page-handler="down" class="btn btn-primary">短信发送</button>
   
</form>
 public async Task<IActionResult> OnPostDown()
        {           

            string url = "https://smssh1.253.com/msg/v1/send/json";

            var response = await url.SetBody(new Dictionary<string, object> { { "account", "" }, { "password", "" }, { "msg", "123456" }, { "phone", "18072707664" } }, "application/json", Encoding.UTF8).PostAsStringAsync();


            return Content(response);

        }


相关文章

点击按钮,禁用提示,加导出word

@page @model xxtsoft.Web.Entry.Pages.sysadmins.kh.kh_outModel @{     Lay...

Razor 遍历 DataTable

@using System.Data <table class="table table-bordered table-striped&n...

asp.net core razor 一个页面多个提交

<form method="post">     <button type="submit...

asp.net core SqlSugar 多库切换

  private readonly SqlSugar.ISqlSugarClient _db;     ...

asp.net core ZipDeploy iis发布 忽略某一件文件夹被删除

  services.AddZipDeploy(o => o.IgnorePathStarting("wwwroot/")); //iis发布...

发表评论    

◎欢迎参与讨论,请在这里发表您的看法、交流您的观点。