WebMarkupMin: Minification not working for pages with response code !=200
Hello,
when i am using minification on 404 or other custom error pages, its totally ignored if i set
HttpContext.Response.StatusCode=404;
you can check the live url here ultrawebz
[CompressContent]
[MinifyHtml]
[MinifyXml]
public ActionResult HttpError404(string message="")
{
//HttpContext.Response.StatusCode=404; minification works only after this commented
ViewBag.msg = message;
return View();
}
but commenting this code is bad practice for seo. i am using webmarkupmin ver 2.5.7 (core) WebMarkupMin.AspNet4.Mvc 2.5.0
regards
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 17 (7 by maintainers)
It works beautifully! 👍🏻 💯