setting the following properties for object in asp.net results in? [Resolved]

Posted by Rajendra.prasad under ASP.NET on 5/6/2011 | Points: 10 | Views : 2430 | Status : [Member] | Replies : 3
Hi,

setting the following properties for object in asp.net results in?
response.buffer=true
response.expiresabsolute=now().subtract(new timespan(1,0,0,0))
response.expires=0
response.cachecontrol="no-cache"

a. session expires
b. clears buffer area
c. avoid page to be cached
d. none

Regards,
Rajendra




Responses

Posted by: Lokesh76 on: 5/6/2011 [Member] Starter | Points: 50

Up
0
Down

Resolved
response.buffer = true/false, meaning of this property that server buffer the response or not based of value true/false. by default its true with IIS version 5.0 and above.

response.expiresabsolute: The ExpiresAbsolute property specifies the date and time at which a page cached on a browser expires. If the user returns to the same page before that date and time, the cached version is displayed. If a time is not specified, the page expires at midnight of that day. If a date is not specified, the page expires at the given time on the day that the script runs.

response.expires: The Expires property specifies the duration of time before a page that is cached on a browser expires. If the user returns to the same page before it expires, the cached version is displayed.

response.cachecontrol="no-cache" means preventing browser cache.

So final output of code is c. avoid page to be cached.



Thanks
Lokesh Kumar

Rajendra.prasad, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Rajendra.prasad on: 5/8/2011 [Member] Starter | Points: 25

Up
0
Down
Hi Lokesh,
Thanks buddy

Regards,
Rajendra

Rajendra.prasad, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Bdevkar11 on: 12/8/2015 [Member] Starter | Points: 25

Up
0
Down
c . Avoid page to be cached

Rajendra.prasad, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response