【发布时间】:2014-04-13 08:32:15
【问题描述】:
我在我的网站中使用了一个短信面板,它为我提供了一个可供使用的 api,当我调试系统并在本地使用它时,它运行良好,但是当我发布网站时,它给出了以下错误:
A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 87.107.121.54:80
这是我正在使用的代码
SendSoapClient client = new SendSoapClient("SendSoap");
ArrayOfString receivers = new ArrayOfString();
receivers .Add("0920xxxxxxx");
ArrayOfString result = client.SendSimpleSMS("username", "password", receivers, "sender number", "message goes here", false);
我已经在我的 global.asax 文件中调用了 web 服务,只是为了检查它是否工作,它只是不工作。我到底做错了什么?
P.S:我在其他不是mvc项目的网站中使用过这个api服务,而只是asp.net网站,它们都工作正常,这是第一次在mvc项目中使用它。
【问题讨论】:
标签: c# asp.net-mvc wcf asp.net-mvc-4