Skip to content

Instantly share code, notes, and snippets.

@wdzajicek
Created November 6, 2018 20:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wdzajicek/a0c6531b40c9a6524db71855e6a44ee5 to your computer and use it in GitHub Desktop.
Save wdzajicek/a0c6531b40c9a6524db71855e6a44ee5 to your computer and use it in GitHub Desktop.
Prevent Caching in IIS Servers!
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<staticContent>
<clientCache cacheControlMode="DisableCache" />
</staticContent>
</system.webServer>
</configuration>
@wdzajicek
Copy link
Author

wdzajicek commented Nov 6, 2018

Take this file and shove it in your IIS folder of which you want the contents to not be cached.

web.config's are relative to the dir they are in, so placing in root would prevent whole site form caching...

@wdzajicek
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment