Universe.Framework.Servers.HttpServer.BaseHttpServer.GetHTML500 C# (CSharp) 메소드

GetHTML500() 공개 메소드

public GetHTML500 ( HttpListenerResponse response ) : byte[]
response System.Net.HttpListenerResponse
리턴 byte[]
        public byte [] GetHTML500 (HttpListenerResponse response)
        {
            // I know this statuscode is dumb, but the client doesn't respond to 404s and 500s
            response.StatusCode = (int)HttpStatusCode.OK;
            response.AddHeader ("Content-type", "text/html");

            string responseString = GetHTTP500 ();
            byte [] buffer = Encoding.UTF8.GetBytes (responseString);
            response.ContentEncoding = Encoding.UTF8;
            return buffer;
        }