473,321 Members | 1,748 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,321 software developers and data experts.

<%@ OutputCache Duration="30" VaryByParam="none" %>

sorry about the previous post, by mistake not completed.

i have an asp.net page with the line
<%@ OutputCache Duration="30" VaryByParam="none" %>

but when i make requests to the page with different parameters, i get different result,

but i tries to check if i set the VaryByParam to none there should be the same output for different parameters, so why does it not work?

TIA, z.

Nov 19 '05 #1
5 4608
z.,

When you make requests with different parameters,
you *should* get different data returned.

That's the *purpose* of parameters, to enable dynamic data
to be returned depending on the parameter sent.

If you set VaryByParam to "none", all that means
is that the *caching* won't vary by parameters.

The *data* will, still, vary by parameters.

A VaryByParam of "categoryID" would create separate
*cache entries* for every categoryID in a catalog, for example.

A VaryByParam of "none", won't *cache* by parameters,
but the *data returned* will, still, vary by parameters.


Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Espa?ol
=====================

"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:eD**************@TK2MSFTNGP09.phx.gbl...
sorry about the previous post, by mistake not completed.

i have an asp.net page with the line
<%@ OutputCache Duration="30" VaryByParam="none" %>

but when i make requests to the page with different parameters, i get
different result,

but i tries to check if i set the VaryByParam to none there should be the
same output for different parameters, so why does it not work?

TIA, z.


Nov 19 '05 #2
i'm trying to understand you

if i have a categoryID parameter for my page.
and i have VaryByParam=none i should get the first cached snapshot of the page what ever parameter is sent after the page being cached.
at least that's what i thought.

so what is happening with this page when it gets 2 different requests, it gives fresh data?

what you mean i your last line (i quote:)
A VaryByParam of "none", won't *cache* by parameters,
but the *data returned* will, still, vary by parameters

so VaryByParam of "none" won't cache the page at all and gives fresh data?
another question:

if i put a response.write of the timestamp in my page_load
of a chached page,
shouldn't the value not change between cached requests?
my method should not execute if the output is being cached, so why does it execute?

TIA, z.


"Juan T. Llibre" <no***********@nowhere.com> wrote in message news:OF**************@TK2MSFTNGP09.phx.gbl...
z.,

When you make requests with different parameters,
you *should* get different data returned.

That's the *purpose* of parameters, to enable dynamic data
to be returned depending on the parameter sent.

If you set VaryByParam to "none", all that means
is that the *caching* won't vary by parameters.

The *data* will, still, vary by parameters.

A VaryByParam of "categoryID" would create separate
*cache entries* for every categoryID in a catalog, for example.

A VaryByParam of "none", won't *cache* by parameters,
but the *data returned* will, still, vary by parameters.


Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Espa?ol
=====================

"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:eD**************@TK2MSFTNGP09.phx.gbl...
sorry about the previous post, by mistake not completed.

i have an asp.net page with the line
<%@ OutputCache Duration="30" VaryByParam="none" %>

but when i make requests to the page with different parameters, i get
different result,

but i tries to check if i set the VaryByParam to none there should be the
same output for different parameters, so why does it not work?

TIA, z.


Nov 19 '05 #3
z,

Could you read these articles,
and then come back with any questions you might still have ?

http://msdn.microsoft.com/library/de...sbestpract.asp

http://msdn.microsoft.com/asp.net/co...sp03282002.asp

From this last article :

VaryByParam: This attribute allows us to control how many cached
versions of the page should be created based on name/value pairs
sent through HTTP POST/GET.

The default value is None.

None implies that only one version of the page is added to the Cache,
and all HTTP GET/POST parameters are simply ignored.

The opposite of the None value is *.

The asterisk implies that all name/value pairs passed in are to be used
to create cached versions of the page.

The granularity can be controlled, however, by naming parameters
(multiple parameter names are separated using semi-colons).

Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Espa?ol
=====================

"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:uD*************@TK2MSFTNGP09.phx.gbl...
i'm trying to understand you

if i have a categoryID parameter for my page.
and i have VaryByParam=none i should get the first cached snapshot of the
page what ever parameter is sent after the page being cached.
at least that's what i thought.

so what is happening with this page when it gets 2 different requests, it
gives fresh data?

what you mean i your last line (i quote:)
A VaryByParam of "none", won't *cache* by parameters,
but the *data returned* will, still, vary by parameters

so VaryByParam of "none" won't cache the page at all and gives fresh data?
another question:

if i put a response.write of the timestamp in my page_load
of a chached page,
shouldn't the value not change between cached requests?
my method should not execute if the output is being cached, so why does it
execute?

TIA, z.


"Juan T. Llibre" <no***********@nowhere.com> wrote in message
news:OF**************@TK2MSFTNGP09.phx.gbl...
z.,

When you make requests with different parameters,
you *should* get different data returned.

That's the *purpose* of parameters, to enable dynamic data
to be returned depending on the parameter sent.

If you set VaryByParam to "none", all that means
is that the *caching* won't vary by parameters.

The *data* will, still, vary by parameters.

A VaryByParam of "categoryID" would create separate
*cache entries* for every categoryID in a catalog, for example.

A VaryByParam of "none", won't *cache* by parameters,
but the *data returned* will, still, vary by parameters.


Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Espa?ol
=====================

"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:eD**************@TK2MSFTNGP09.phx.gbl...
sorry about the previous post, by mistake not completed.

i have an asp.net page with the line
<%@ OutputCache Duration="30" VaryByParam="none" %>

but when i make requests to the page with different parameters, i get
different result,

but i tries to check if i set the VaryByParam to none there should be the
same output for different parameters, so why does it not work?

TIA, z.


Nov 19 '05 #4
ok everything is cool, the articles tell what i thought in the first place.
i found my problem

using response.flush inside the code actually cancels the caching.

how should i know about it?

i don't think anywhere this is told.

i had to put and remove all kinds of functions in my code in order to trace this.

is this a must?

who knows......

"Juan T. Llibre" <no***********@nowhere.com> wrote in message news:eA**************@TK2MSFTNGP14.phx.gbl...
z,

Could you read these articles,
and then come back with any questions you might still have ?

http://msdn.microsoft.com/library/de...sbestpract.asp

http://msdn.microsoft.com/asp.net/co...sp03282002.asp

From this last article :

VaryByParam: This attribute allows us to control how many cached
versions of the page should be created based on name/value pairs
sent through HTTP POST/GET.

The default value is None.

None implies that only one version of the page is added to the Cache,
and all HTTP GET/POST parameters are simply ignored.

The opposite of the None value is *.

The asterisk implies that all name/value pairs passed in are to be used
to create cached versions of the page.

The granularity can be controlled, however, by naming parameters
(multiple parameter names are separated using semi-colons).

Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Espa?ol
=====================

"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:uD*************@TK2MSFTNGP09.phx.gbl...
i'm trying to understand you

if i have a categoryID parameter for my page.
and i have VaryByParam=none i should get the first cached snapshot of the
page what ever parameter is sent after the page being cached.
at least that's what i thought.

so what is happening with this page when it gets 2 different requests, it
gives fresh data?

what you mean i your last line (i quote:)
A VaryByParam of "none", won't *cache* by parameters,
but the *data returned* will, still, vary by parameters

so VaryByParam of "none" won't cache the page at all and gives fresh data?
another question:

if i put a response.write of the timestamp in my page_load
of a chached page,
shouldn't the value not change between cached requests?
my method should not execute if the output is being cached, so why does it
execute?

TIA, z.


"Juan T. Llibre" <no***********@nowhere.com> wrote in message
news:OF**************@TK2MSFTNGP09.phx.gbl...
z.,

When you make requests with different parameters,
you *should* get different data returned.

That's the *purpose* of parameters, to enable dynamic data
to be returned depending on the parameter sent.

If you set VaryByParam to "none", all that means
is that the *caching* won't vary by parameters.

The *data* will, still, vary by parameters.

A VaryByParam of "categoryID" would create separate
*cache entries* for every categoryID in a catalog, for example.

A VaryByParam of "none", won't *cache* by parameters,
but the *data returned* will, still, vary by parameters.


Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Espa?ol
=====================

"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:eD**************@TK2MSFTNGP09.phx.gbl...
sorry about the previous post, by mistake not completed.

i have an asp.net page with the line
<%@ OutputCache Duration="30" VaryByParam="none" %>

but when i make requests to the page with different parameters, i get
different result,

but i tries to check if i set the VaryByParam to none there should be the
same output for different parameters, so why does it not work?

TIA, z.


Nov 19 '05 #5
Glad to see you worked it out...

Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Espa?ol
=====================

"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
ok everything is cool, the articles tell what i thought in the first place.
i found my problem

using response.flush inside the code actually cancels the caching.

how should i know about it?

i don't think anywhere this is told.

i had to put and remove all kinds of functions in my code in order to trace
this.

is this a must?

who knows......

"Juan T. Llibre" <no***********@nowhere.com> wrote in message
news:eA**************@TK2MSFTNGP14.phx.gbl...
z,

Could you read these articles,
and then come back with any questions you might still have ?

http://msdn.microsoft.com/library/de...sbestpract.asp

http://msdn.microsoft.com/asp.net/co...sp03282002.asp

From this last article :

VaryByParam: This attribute allows us to control how many cached
versions of the page should be created based on name/value pairs
sent through HTTP POST/GET.

The default value is None.

None implies that only one version of the page is added to the Cache,
and all HTTP GET/POST parameters are simply ignored.

The opposite of the None value is *.

The asterisk implies that all name/value pairs passed in are to be used
to create cached versions of the page.

The granularity can be controlled, however, by naming parameters
(multiple parameter names are separated using semi-colons).

Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Espa?ol
=====================

"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:uD*************@TK2MSFTNGP09.phx.gbl...
i'm trying to understand you

if i have a categoryID parameter for my page.
and i have VaryByParam=none i should get the first cached snapshot of the
page what ever parameter is sent after the page being cached.
at least that's what i thought.

so what is happening with this page when it gets 2 different requests, it
gives fresh data?

what you mean i your last line (i quote:)
A VaryByParam of "none", won't *cache* by parameters,
but the *data returned* will, still, vary by parameters

so VaryByParam of "none" won't cache the page at all and gives fresh
data?
another question:

if i put a response.write of the timestamp in my page_load
of a chached page,
shouldn't the value not change between cached requests?
my method should not execute if the output is being cached, so why does it
execute?

TIA, z.


"Juan T. Llibre" <no***********@nowhere.com> wrote in message
news:OF**************@TK2MSFTNGP09.phx.gbl...
z.,

When you make requests with different parameters,
you *should* get different data returned.

That's the *purpose* of parameters, to enable dynamic data
to be returned depending on the parameter sent.

If you set VaryByParam to "none", all that means
is that the *caching* won't vary by parameters.

The *data* will, still, vary by parameters.

A VaryByParam of "categoryID" would create separate
*cache entries* for every categoryID in a catalog, for example.

A VaryByParam of "none", won't *cache* by parameters,
but the *data returned* will, still, vary by parameters.


Juan T. Llibre
ASP.NET MVP
http://asp.net.do/foros/
Foros de ASP.NET en Espa?ol
=====================

"z. f." <zi**@info-scopeREMSPAM.co.il> wrote in message
news:eD**************@TK2MSFTNGP09.phx.gbl...
sorry about the previous post, by mistake not completed.

i have an asp.net page with the line
<%@ OutputCache Duration="30" VaryByParam="none" %>

but when i make requests to the page with different parameters, i get
different result,

but i tries to check if i set the VaryByParam to none there should be
the
same output for different parameters, so why does it not work?

TIA, z.



Nov 19 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Christian Schmidbauer | last post by:
Hello! I prepare my XML document like this way: ------------------------------------------------------- PrintWriter writer; Document domDocument; Element domElement; // Root tag
4
by: matatu | last post by:
Hi to all, I have a xml file, a substring like: &lt;a href=&quot;#&quot;&gt;text&lt;/a&gt; which after an xslt trasform is rendered as (using xsl:output method html): &lt;a...
2
by: Eshrath | last post by:
Hi, What I am trying to do: ======================= I need to form a table in html using the xsl but the table that is formed is quite long and cannot be viewed in our application. So we are...
2
by: Donald Firesmith | last post by:
I am having trouble having Google Adsense code stored in XSL converted properly into HTML. The <> unfortunately become &lt; and &gt; and then no longer work. XSL code is: <script...
4
by: higabe | last post by:
Three questions 1) I have a string function that works perfectly but according to W3C.org web site is syntactically flawed because it contains the characters </ in sequence. So how am I...
34
by: Mark Moore | last post by:
It looks like there's a pretty serious CSS bug in IE6 (v6.0.2800.1106). The HTML below is validated STRICT HTML 4.01 and renders as I would expect in Opera, FrontPage, and Netscape. For some...
11
by: Les Paul | last post by:
I'm trying to design an HTML page that can edit itself. In essence, it's just like a Wiki page, but my own very simple version. It's a page full of plain old HTML content, and then at the bottom,...
10
by: Jon Noring | last post by:
Out of curiosity, may a CDATA section appear within an attribute value with datatype CDATA? And if so, how about other attribute value datatypes which accept the XML markup characters? To me,...
9
by: Eric Lindsay | last post by:
I can't figure how to best display little snippets of shell script using <pre>. I just got around to organising to bulk validate some of my web pages, and one of the problems occurs with Bash...
6
by: tentstitcher | last post by:
Hi all: I have a source xml document with an element of type string. This element contains something like the following: <stringData> &lt;Header&gt; &lt;Body&gt; </stringData> I would like to apply an...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.