IIS 7.5 How do you add a Dynamic HTTP Expires Header

前端 未结 2 1885
失恋的感觉
失恋的感觉 2020-12-12 07:20

In IIS 7.5, you can add static HTTP Response headers, but I want to add an \"Expires\" header that always specifies a date that is 7 days in the future.

I\'m running

2条回答
  •  我在风中等你
    2020-12-12 08:12

    This is a standard feature of IIS. The HTTP Response Headers module allows you to set this common header. This results in the following web.config:

    
    
        
            
                
            
        
    
    

    You should do this only in the directories where you want this header to be send. Typically only directories with static content.

提交回复
热议问题