首页 新闻 会员 周边

win7 Ajax service "This operation is not supported for a relative URI."

0
悬赏园豆:50 [待解决问题]

前言:前天兴起 把系统由XP换成了Win7,就有了下面的问题,这个问题在XP是没有的。

描述:用户注册,当用户填好用户名,就通过javascript去验证是否有效

key code: 

<asp:ScriptManager ID="uxScriptManager" runat="server" EnablePageMethods="true">
        <Services>
            <asp:ServiceReference Path="/Services/AjaxService.svc" />
        </Services>
  </asp:ScriptManager>

---------------------------------

调用: AjaxService.CheckUserNameAvailability(userName, successFn, failedFn);

 

错误信息

https://www.dev.zecco.com/Services/AjaxService.svc/jsdebug (500 Internal Server Error)

直接访问service 报错如图

问题补充:

http://stackoverflow.com/questions/5072032/ajax-enabled-wcf-service-not-working-when-published

和我的问题一样 希望对问题的描述有帮助

夏小莫的主页 夏小莫 | 初学一级 | 园豆:136
提问于:2011-10-25 17:49
< >
分享
所有回答(1)
0

1、检查你的地址是否正确

2、检查是不是这个问题:http://www.cnblogs.com/Ricky81317/archive/2009/04/08/1430221.html

artwl | 园豆:16736 (专家六级) | 2011-10-26 10:02

以下是web.config配置:

<endpointBehaviors>
                <behavior name="Zecco.Portal.Web.Services.AjaxServiceAspNetAjaxBehavior">
                    <enableWebScript />
                </behavior>

</endpointBehaviors>

<service name="Zecco.Portal.Web.Services.AjaxService">
                <endpoint address="" behaviorConfiguration="Zecco.Portal.Web.Services.AjaxServiceAspNetAjaxBehavior"
                 binding="webHttpBinding" bindingConfiguration="webTransportBinding"
                 name="HttpsEndpoint" contract="Zecco.Portal.Web.Services.AjaxService" />
 </service>

因为对WCF不是很熟 所以只好贴出代码 期待纠错(为虾米XP,win2000, win2003都咩得问题呢)

支持(0) 反对(0) 夏小莫 | 园豆:136 (初学一级) | 2011-10-26 11:13
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册