之前会出现"服务器无法在已发送 HTTP 标头之后设置状态"的问题,本地调试不报错,但是上产线就会报错
解决的思路是:
var response = Request.CreateResponse(HttpStatusCode.Redirect);
response.Headers.Location = new Uri(req.R);
return response;
之前会出现"服务器无法在已发送 HTTP 标头之后设置状态"的问题,本地调试不报错,但是上产线就会报错
解决的思路是:
var response = Request.CreateResponse(HttpStatusCode.Redirect);
response.Headers.Location = new Uri(req.R);
return response;