App_offline.htm, CSS, images, and aspnet_isapi.dll

后端 未结 2 1566
生来不讨喜
生来不讨喜 2021-02-07 21:11

So, the site I\'m working on is using urlrewriting in coordination with aspnet_isapi.dll (everything is mapped to it). I put up my app_offline.htm file, and all the text shows,

相关标签:
2条回答
  • 2021-02-07 21:24

    @JeremyWeir is correct. IIS stops serving sub resources in the prescense of app_offline.htm A way around this is to embed the content in the page directly by using:

    1) Encode Images inside Html 2) Internal Style Sheets 3) the same for your javascript

    This isn't the easiest to maintain but it does give you control over the appearance of the content displayed on the page.

    0 讨论(0)
  • 2021-02-07 21:49

    It's because if the webserver sees an App_Offline.htm file, it serves that file for every request in the site - even images. You have to serve images from another site. Or you can try something like this http://en.wikipedia.org/wiki/Data_URI_scheme

    0 讨论(0)
提交回复
热议问题