Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I turn off output cache via web.config in asp.net mvc 4 app

How can I turn off output cache via web.debug.config in asp.net mvc 4 app? I try to do it:

web.debug.config

  <caching>
    <outputCache enableOutputCache="false" />
  </caching>

Why doesn't it work?

like image 350
Konstantin Avatar asked Dec 12 '13 09:12

Konstantin


1 Answers

The web.config.debug file is used only when you build a deployment package . If you run your site locally in Cassini for example it is completely ignored. So you may try disabling cache in your web.config:

<system.web>
    <caching>
        <outputCache enableOutputCache="false" />
    </caching>
</system.web>
like image 171
Nilesh Gajare Avatar answered Nov 01 '22 22:11

Nilesh Gajare