I have an old website that displays content from umbraco per page. This is done by using a pageload to call a webservice and render umbraco html content to a literal control. i.e.
HttpWebRequest request = (HttpWebRequest)WebRequest.Create("http://111.111.111.111:8080/api/PageContentApi?id=1122");
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
if (response.StatusCode == HttpStatusCode.OK)
{
Stream stream = response.GetResponseStream();
using (StreamReader reader = new StreamReader(stream))
{
string html = reader.ReadToEnd();
aboutText.Text = html;
}
}
How would I accomplish this same rendering but in a MVC way for a hot towel spa application. How should this be structured per view when a single page application is designed to load most content at start?