var response = Request.CreateResponse(HttpStatusCode.OK); response.Content = new ByteArrayContent(data); //data为二进制图片数据 response.Content.Headers.ContentType = new MediaTypeHeaderValue("image/png"); return response;
var response = Request.CreateResponse(HttpStatusCode.OK); response.Content = new ByteArrayContent(data); //data为二进制图片数据 response.Content.Headers.ContentType = new MediaTypeHeaderValue("image/png"); return response;