404 error while caching .aspx pages with HTML5 cache manifest

Could anyone cache .aspx pages using the HTML cache manifest? I port the html application to asp.net (and mvc2) and I get a 404 error when trying to cache any * .aspx page. Other files are still stored as usual (.js, .css, etc.). I changed permissions, handlers and file names and still no luck. Below is the actual manifest:

CACHE MANIFEST # This file was generated at 2/28/2011 4:03 PM CACHE: /Content/Site.css /Content/Table_style.css /Scripts/jquery-1.5.min.js /Scripts/json.js /Scripts/persist-all.js /Views/Data/Details.aspx /Views/Data/NotFound.aspx /Views/Data/OffLine.aspx /Views/Data/OnLine.aspx /Views/Data/Test.aspx /Views/Home/About.aspx /Views/Home/Index.aspx /Views/Shared/Error.aspx 
0
source share
1 answer

Each request passes through the controller, and not directly to the view. Look at the URL in your browser, it never ends with .aspx (when using MVC).

It looks like you have Data and Home controller. Your urls will probably look something like this:

  • / Data / Details
  • / Data / NotFound
  • / Data / OffLine
  • / Data / OnLine
  • / Data / test
  • /ABOUT
  • /

This is the URL you need in the manifest of your cache.

+1
source

Source: https://habr.com/ru/post/1484510/


All Articles