{"id":404,"date":"2005-09-30T18:40:49","date_gmt":"2005-09-30T10:40:49","guid":{"rendered":"http:\/\/blog.axqd.net\/?p=404"},"modified":"2005-09-30T18:40:49","modified_gmt":"2005-09-30T10:40:49","slug":"%e5%8f%91%e5%b8%83web-services","status":"publish","type":"post","link":"https:\/\/blog.axqd.net\/?p=404","title":{"rendered":"\u53d1\u5e03Web Services"},"content":{"rendered":"<p>\u7b14\u8bb0\u672c\u4e0aRelease\u540e\u4e00\u5207\u6b63\u5e38\u7684Web Services\uff0c\u90e8\u7f72\u5230\u53e6\u5916\u4e00\u53f02003\u7684\u670d\u52a1\u5668\u4e0a\uff0c\u51fa\u73b0\u4e24\u4e2a\u95ee\u9898\uff1a<\/p>\n<p>1\u3001Critical Error\uff1a<\/p>\n<p>&#8230;\u6ca1\u6709\u6743\u9650\u8bbf\u95ee\u6ce8\u518c\u8868<\/p>\n<p>\u5176\u5b9e\u53ea\u662f\u5728\u5199\u5165EventLog\u7684\u65f6\u5019ASPNET\u7684\u6743\u9650\u4e0d\u591f\uff0c\u4e0d\u8fc7\u5947\u602a\u7684\u662f\u628aASPNET\u548c\u533f\u540d\u5e10\u6237\u52a0\u5165Administrator\u7ec4\uff0c\u91cd\u542f\uff0c\u597d\u50cf\u6743\u9650\u8fd8\u662f\u4e0d\u591f&gt;.&lt;<\/p>\n<p>\u67e5\u770b\u5176\u5217\u51fa\u7684\u8ddf\u8e2a\u5806\u6808\uff0c\u53d1\u73b0\u597d\u50cf\u662fEnterprise Library\u4e2dADO.NET\u8fde\u63a5\u6570\u636e\u5e93\u7684\u95ee\u9898\uff0c\u5728\u7f51\u4e0a\u67e5\u4e86\u67e5\uff0c\u6709\u7528\u7684\u6587\u7ae0\u4e0d\u591a\uff0c\u6700\u540e\u5c45\u7136\u5c31\u5728EntLib\u7684FAQ\u91cc,\u53d1\u73b0\u662f\u6ca1\u6709\u6b63\u786e\u90e8\u7f72EnterLib\u7a0b\u5e8f\u96c6\u7684\u95ee\u9898\u3002<\/p>\n<p>\u5b89\u88c5\u7a0b\u5e8f\u5de5\u5177(Installutil.exe)<br \/>\n\u5141\u8bb8\u901a\u8fc7\u6267\u884c\u6307\u5b9a\u7a0b\u5e8f\u96c6\u7684\u5b89\u88c5\u7a0b\u5e8f\u7ec4\u4ef6\u6765\u5b89\u88c5\u548c\u5378\u8f7d\u670d\u52a1\u5668\u8d44\u6e90\u3002<br \/>\n\u6ce8\u610f: \u5728\u201c%windir%Microsoft.NETFrameworkv1.1.xxxx\u201d\u4e2d\u53ef\u4ee5\u627e\u5230Installutil.exe\uff0c\u5176\u4e2dxxxx\u662f\u60a8\u4f7f\u7528\u7684 .NET Framework \u7684\u5185\u90e8\u7248\u672c\u53f7\u3002<\/p>\n<p><code>Installutil Microsoft.Practices.EnterpriseLibrary.Common.dll<br \/>\nInstallutil Microsoft.Practices.EnterpriseLibrary.Configuration.dll<br \/>\nInstallutil Microsoft.Practices.EnterpriseLibrary.Data.dll<\/code><\/p>\n<p>\u4e00\u5207\u6062\u590d\u6b63\u5e38\u3002<\/p>\n<p>\u4e0d\u8fc7\u8fd8\u662f\u4e0d\u77e5\u9053\u4e3a\u4ec0\u4e48\u4ed6\u7684\u7a0b\u5e8f\u96c6\u90e8\u7f72\u7684\u65f6\u5019\u5fc5\u987bInstall\uff0c\u800c\u81ea\u5df1\u7684dll\u5c31\u4e0d\u7528\u8fd9\u4e00\u6b65\u3002<\/p>\n<p>PS:<br \/>\n\u5220\u9664\u7528<br \/>\nInstallutil \/u xxx.dll<\/p>\n<p>2\u3001localhost\u8bbf\u95ee\u6ca1\u6709\u95ee\u9898\uff0c\u4f46\u7528www.xxx.com\u8bbf\u95ee\uff0c\u51fa\u9519<\/p>\n<p>\u5728 .NET Framework 1.1 \u8fdc\u7a0b\u73af\u5883\u4e2d\uff0c\u9ed8\u8ba4\u60c5\u51b5\u4e0b HTTP GET \u548c HTTP POST \u540c\u65f6\u88ab\u7981\u7528\u3002\u8fd9\u662f\u51fa\u4e8e\u5b89\u5168\u65b9\u9762\u7684\u8003\u8651\u3002<br \/>\n\u5f53 Web \u670d\u52a1\u5347\u7ea7\u5230 .NET Framework 1.1 \u540e\uff0c\u5e94\u7528\u7a0b\u5e8f\u4f7f\u7528 HTTP GET \u6216 HTTP POST \u8c03\u7528 Web \u670d\u52a1\u65f6\u4f1a\u5931\u8d25\u3002<br \/>\n\u8fd9\u4e9b\u5e94\u7528\u7a0b\u5e8f\u4f1a\u6536\u5230\u4ee5\u4e0b\u4e00\u6761\u9519\u8bef\u4fe1\u606f System.Net.WebException\u6307\u51fa\u65e0\u6cd5\u8bc6\u522b\u8bf7\u6c42\u683c\u5f0f\u3002<\/p>\n<p>\u7531\u4e8e\u4f7f\u7528POST\uff0c\u73b0\u5728\u5df2\u57fa\u672c\u4e0d\u53ef\u80fd\u8f6c\u6210SOAP\u534f\u8bae\uff0c\u53ea\u6709\u5c06\u5176\u6253\u5f00\uff0c\u66f4\u6539Web.Config\u6587\u4ef6\uff1a<br \/>\n<code>&lt;configuration&gt;<br \/>\n&lt;system.web&gt;<br \/>\n&lt;webServices&gt;<br \/>\n&lt;protocols&gt;<br \/>\n&lt;!--<br \/>\n&lt;add name=\"HttpGet\"&gt;<br \/>\n--&gt;<br \/>\n&lt;add name=\"HttpPost\"\/&gt;<br \/>\n&lt;\/protocols&gt;<br \/>\n&lt;\/webServices&gt;<br \/>\n&lt;\/system.web&gt;<br \/>\n&lt;\/configuration&gt;<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u7b14\u8bb0\u672c\u4e0aRelease\u540e\u4e00\u5207\u6b63\u5e38\u7684Web Services\uff0c\u90e8\u7f72\u5230\u53e6\u5916\u4e00\u53f02003\u7684\u670d\u52a1\u5668\u4e0a\uff0c\u51fa\u73b0\u4e24\u4e2a\u95ee\u9898\uff1a  &hellip; <a href=\"https:\/\/blog.axqd.net\/?p=404\" class=\"more-link\">\u7ee7\u7eed\u9605\u8bfb<span class=\"screen-reader-text\">\u201c\u53d1\u5e03Web Services\u201d<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[14],"tags":[],"class_list":["post-404","post","type-post","status-publish","format-standard","hentry","category-net"],"_links":{"self":[{"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/posts\/404","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=404"}],"version-history":[{"count":0,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=\/wp\/v2\/posts\/404\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.axqd.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=404"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=404"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.axqd.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=404"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}