开发者

.NET WCF SVC file downloaded instead of being executed

开发者 https://www.devze.com 2023-01-22 12:45 出处:网络
I am using a WDF Service in my web application which I am accessing very jquery. Locally it works fine, but on my test server (IIS7) it does not.

I am using a WDF Service in my web application which I am accessing very jquery. Locally it works fine, but on my test server (IIS7) it does not.

I tried accessing the .svc via the url (www.mydomain.de/Services/MyService.svc) expecting that I get the same page as offline ("This is a WCF service, meta开发者_运维技巧data publishing is disabled ....". Instead, the .svc file gets downloaded and opens in Visual Studio.

Is this a web.config problem (it works offline but I don't have II7 offline) or is it a problem that file associations in IIs7 are not correct? My Testserver is running in a shared hosting environment and I have only very limited access (Parallels Plesk Panel 9), so if this is an IIS7 problem I need to go through the webhoster...

Any Feedback welcome.


Check the web.config.... on the machine level. Can be the regtistration for .svc files got delted. Limited access means likely the hoster, out of idiocy, cluelessness of due to a business decision simply did not enable / disabled .svc files. Without the registration... the file will be "served" (transmitted).

Not a lot you can do - take it with their support. .NET 4.0 may not be properly installed. or, as I said, it is a willfull decision.

The fact that they use IIS 7 says a lot - they should use 7.5 for quite a time now.


I would recommend re-registering the .NET framework 4.0 with IIS using the aspnet_regiis.exe tool

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号