How to disable View State MAC globally?

Jader Dias picture Jader Dias · Apr 15, 2010 · Viewed 20.7k times · Source

I'm tired of including

EnableViewStateMac="false"

in every page. How to do that globally?

Answer

Nick Craver picture Nick Craver · Apr 15, 2010

You can disable it on the <pages> element in the web.config, like this:

<configuration>
  <system.web>
    <pages enableViewStateMac="False" />
  </system.web>
</configuration>