I have a self-hosted WCF service running as a windows service using the WebAPI to handle the REST stuff and it works great.
I realise that I should really use IIS or similar to dish out actual web pages, but is there ANY way to get a service call to return "just" html?
Even if I specify "BodyStye Bare", I still get the XML wrapper around the actual HTML, ie
<?xml version="1.0" encoding="UTF-8"?>
<string> html page contents .... </string>
[WebGet(UriTemplate = "/start", BodyStyle = WebMessageBodyStyle.Bare)]
public string StartPage()
{
return System.IO.File.ReadAllText(@"c:\whatever\somefile.htm");
}
Is there any way to do this or should I give up?