自托管的简单HTML页面 [英] Self-hosting simple HTML page

查看:426
本文介绍了自托管的简单HTML页面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个自托管的Web服务,它使用带有NetTcpBinding绑定的System.ServiceModel.ServiceHost(即WCF),可以在Windows服务中完美运行.但是,我想在网站上将信息页放在一个人可以访问的端口上 在浏览器中.我想将IIS放在图片之外,所以我想将HTML页面托管在同一服务中.我认为这应该相对简单,但是我不知道从哪里/如何开始.我将如何去做?

I have a self-hosted web service, using System.ServiceModel.ServiceHost (i.e. WCF) with a NetTcpBinding binding, running beautifully within a Windows service. However, I'd like to put an information page at the site on the same port that a person could access in a browser.  I'd like to keep IIS out of the pictures, so I'd like to host the HTML page in the same service.  I assume this should be relatively simple, but I have no idea where/how to start.  How would I go about doing that?

我读过的一件事是,不能在同一端口上使用两个不同的绑定.是真的吗?如果是这样,那么也许我想做的事情是不可能的.

One thing I've read is that one can't use two different bindings on the same port.  Is that true?  If it is, then perhaps what I'm attempting to do is impossible.

谢谢!

布拉德.

推荐答案

所以我想将HTML页面托管在同一服务中.

WCF服务,SOA解决方案和工作都不是要显示任何形式的UI页面或形式,也不是Windows服务的工作.

A WCF service, a SOA solution,  job's is not to be displaying UI pages or forms of any sort nor is it a Windows service's job either.

http://www.codeproject.com/Articles/515253/Service-Oriented -体系结构和WCF

 我想将IIS排除在图片之外.

如果要这样做,则需要学习AngularJS.

If you want to do that, then you need to learn AngularJS.

https://en.wikipedia.org/wiki/AngularJS


这篇关于自托管的简单HTML页面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆