OutputCacheSection

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I cannot figure out the exact syntax and placement for the
"OutputCacheSection" portion of web.config. Which sub-section does it go in?
What are the exact properties and sub-tags which it supports? I can't find a
description of how to use this in the web.config file instead of using it
programatically.

Help?

Thanks.

Alex
 
Eliyahu -

Thanks. But I've been there already. What I'm confused about is that the
documentation says there's an "OutputCacheSECTION" portion in web.config (I
think different from the "OutputCache SETTINGS" section). Basically, I want
to try turning all page caching OFF in one centralized location in my
configuration, without having to touch eaqch of my pages, but I can't figure
out exactly where that should go and what the syntax should be.

Thanks.

Alex

Eliyahu Goldin said:
http://msdn2.microsoft.com/en-us/library/ms178606.aspx

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net


Alex Maghen said:
I cannot figure out the exact syntax and placement for the
"OutputCacheSection" portion of web.config. Which sub-section does it go
in?
What are the exact properties and sub-tags which it supports? I can't find
a
description of how to use this in the web.config file instead of using it
programatically.

Help?

Thanks.

Alex
 
Example:

<?xml version="1.0"?>
<configuration>
<outputCache enableOutputCache="false"
enableFragmentCache="false"
sendCacheControlHeader="false"
omitVaryStar="false">
</outputCache>
<appSettings/>
<connectionStrings/>
<system.web>

HTH,
Peter
--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net




Alex Maghen said:
Eliyahu -

Thanks. But I've been there already. What I'm confused about is that the
documentation says there's an "OutputCacheSECTION" portion in web.config (I
think different from the "OutputCache SETTINGS" section). Basically, I want
to try turning all page caching OFF in one centralized location in my
configuration, without having to touch eaqch of my pages, but I can't figure
out exactly where that should go and what the syntax should be.

Thanks.

Alex

Eliyahu Goldin said:
http://msdn2.microsoft.com/en-us/library/ms178606.aspx

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net


Alex Maghen said:
I cannot figure out the exact syntax and placement for the
"OutputCacheSection" portion of web.config. Which sub-section does it go
in?
What are the exact properties and sub-tags which it supports? I can't find
a
description of how to use this in the web.config file instead of using it
programatically.

Help?

Thanks.

Alex
 
Peter -

I've tried placing this block as I *think* you have it in your sample, which
is inside

web.config
<configuration>
<outputCache>
...
</outputCache>

<system.web>
...
</system.web>
</configuration>

But I'm getting an error: "Could not find schema information for the element
'outputCache'." Any idea why?

Thanks.

Alex



Peter Bromberg said:
Example:

<?xml version="1.0"?>
<configuration>
<outputCache enableOutputCache="false"
enableFragmentCache="false"
sendCacheControlHeader="false"
omitVaryStar="false">
</outputCache>
<appSettings/>
<connectionStrings/>
<system.web>

HTH,
Peter
--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net




Alex Maghen said:
Eliyahu -

Thanks. But I've been there already. What I'm confused about is that the
documentation says there's an "OutputCacheSECTION" portion in web.config (I
think different from the "OutputCache SETTINGS" section). Basically, I want
to try turning all page caching OFF in one centralized location in my
configuration, without having to touch eaqch of my pages, but I can't figure
out exactly where that should go and what the syntax should be.

Thanks.

Alex

Eliyahu Goldin said:
http://msdn2.microsoft.com/en-us/library/ms178606.aspx

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net


I cannot figure out the exact syntax and placement for the
"OutputCacheSection" portion of web.config. Which sub-section does it go
in?
What are the exact properties and sub-tags which it supports? I can't find
a
description of how to use this in the web.config file instead of using it
programatically.

Help?

Thanks.

Alex
 
Alex,
sorry about that. It should look like this (I tested it):

<system.web>
<caching>
<outputCache enableOutputCache="false"
enableFragmentCache="false"
sendCacheControlHeader="false"
omitVaryStar="false">
</outputCache>
</caching>

--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net




Alex Maghen said:
Peter -

I've tried placing this block as I *think* you have it in your sample, which
is inside

web.config
<configuration>
<outputCache>
...
</outputCache>

<system.web>
...
</system.web>
</configuration>

But I'm getting an error: "Could not find schema information for the element
'outputCache'." Any idea why?

Thanks.

Alex



Peter Bromberg said:
Example:

<?xml version="1.0"?>
<configuration>
<outputCache enableOutputCache="false"
enableFragmentCache="false"
sendCacheControlHeader="false"
omitVaryStar="false">
</outputCache>
<appSettings/>
<connectionStrings/>
<system.web>

HTH,
Peter
--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net




Alex Maghen said:
Eliyahu -

Thanks. But I've been there already. What I'm confused about is that the
documentation says there's an "OutputCacheSECTION" portion in web.config (I
think different from the "OutputCache SETTINGS" section). Basically, I want
to try turning all page caching OFF in one centralized location in my
configuration, without having to touch eaqch of my pages, but I can't figure
out exactly where that should go and what the syntax should be.

Thanks.

Alex

:

http://msdn2.microsoft.com/en-us/library/ms178606.aspx

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net


I cannot figure out the exact syntax and placement for the
"OutputCacheSection" portion of web.config. Which sub-section does it go
in?
What are the exact properties and sub-tags which it supports? I can't find
a
description of how to use this in the web.config file instead of using it
programatically.

Help?

Thanks.

Alex
 
Thanks so much. This does the job. Mind if I ask for one thing further?...

What if I want all of my pages to remin uncached which are associated with a
specific MasterPage, but I want the <LINK>ed StyleSheet from that MasterPage
to be cached? Can I set Page Caching settings in a MasterPage or in the
MasterPage's CodeBehind? If so, how (if possible) can I override the general
"don't cache" setting so that the <LINK>ed CSS file can be cached?

Thanks much for your help!

Alex


Peter Bromberg said:
Alex,
sorry about that. It should look like this (I tested it):

<system.web>
<caching>
<outputCache enableOutputCache="false"
enableFragmentCache="false"
sendCacheControlHeader="false"
omitVaryStar="false">
</outputCache>
</caching>

--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net




Alex Maghen said:
Peter -

I've tried placing this block as I *think* you have it in your sample, which
is inside

web.config
<configuration>
<outputCache>
...
</outputCache>

<system.web>
...
</system.web>
</configuration>

But I'm getting an error: "Could not find schema information for the element
'outputCache'." Any idea why?

Thanks.

Alex



Peter Bromberg said:
Example:

<?xml version="1.0"?>
<configuration>
<outputCache enableOutputCache="false"
enableFragmentCache="false"
sendCacheControlHeader="false"
omitVaryStar="false">
</outputCache>
<appSettings/>
<connectionStrings/>
<system.web>

HTH,
Peter
--
Site: http://www.eggheadcafe.com
UnBlog: http://petesbloggerama.blogspot.com
Short urls & more: http://ittyurl.net




:

Eliyahu -

Thanks. But I've been there already. What I'm confused about is that the
documentation says there's an "OutputCacheSECTION" portion in web.config (I
think different from the "OutputCache SETTINGS" section). Basically, I want
to try turning all page caching OFF in one centralized location in my
configuration, without having to touch eaqch of my pages, but I can't figure
out exactly where that should go and what the syntax should be.

Thanks.

Alex

:

http://msdn2.microsoft.com/en-us/library/ms178606.aspx

--
Eliyahu Goldin,
Software Developer & Consultant
Microsoft MVP [ASP.NET]
http://msmvps.com/blogs/egoldin
http://usableasp.net


I cannot figure out the exact syntax and placement for the
"OutputCacheSection" portion of web.config. Which sub-section does it go
in?
What are the exact properties and sub-tags which it supports? I can't find
a
description of how to use this in the web.config file instead of using it
programatically.

Help?

Thanks.

Alex
 
Hi Alex,

A linked stylesheet file is a static web resource that is cached by browser
(if browser is caching files), which is not affected by the @ OutputCache
settings:

#@ OutputCache
http://msdn2.microsoft.com/en-us/library/hdxfb6cy.aspx
Declaratively controls the output caching policies of an ASP.NET page or a
user control contained in a page.


I noticed this post is related to one of your other posts that is also
discussing about stylesheet files cache. Please feel free to reply in
either post if you have anything unclear. Thanks.

Regards,
Walter Wang ([email protected], remove 'online.')
Microsoft Online Community Support

==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================

This posting is provided "AS IS" with no warranties, and confers no rights.
 
Back
Top