Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 417289
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T18:33:56+00:00 2026-05-12T18:33:56+00:00

Calling http://foo/home/cachetest for [UrlRoute(Path = home/cachetest)] [OutputCache(Duration = 10, VaryByParam = none)] public ActionResult

  • 0

Calling

http://foo/home/cachetest

for

[UrlRoute(Path = "home/cachetest")]
[OutputCache(Duration = 10, VaryByParam = "none")]
public ActionResult CacheTest()
{
    return Content(DateTime.Now.ToString());
}

will show the same content for every 10 seconds no matter how often i refresh page.

Is it possible to easily add sliding expiration so it would NOT change after 10 seconds in case i have refreshed the page?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T18:33:56+00:00Added an answer on May 12, 2026 at 6:33 pm

    Been reading the source for the OutputCacheAttribute and I don’t think there’s an easy way to do this.

    You’re most likely going to need to create your own solution.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm calling the following URL using YQL http://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20yahoo.finance.quotes%20where%20symbol%20in%20(%22UTG.L%22)%0A%09%09&format=json&env=http%3A%2F%2Fdatatables.org%2Falltables.env&callback=cbfunc this returns the following in JSON
Calling the ajax called URL works well without ajax eg. http://localhost/ci/controller/method/param_value . But using
http://linux.die.net/man/2/mlockall mlockall () locks all of the calling process's virtual address space into RAM,
alt text http://img179.imageshack.us/img179/7827/textwriter.jpg the tf.txt file has 0 bytes and when calling this method
I'm looking at the http://digitalbush.com/projects/masked-input-plugin/ I'm calling it like this: $(control).mask('999-999-9999'); And I don't
I'm calling a web API exposed by TheyWorkForYou (TWFI). http://www.theyworkforyou.com/api/ I'm using the Python
According to one of the man pages http://www.php.net/manual/en/language.oop5.static.php : Calling non-static methods statically generates
I'm having problems with variable scopes when calling thread http calls inside a remotely
Errors while calling int getopt function from http://code.google.com/p/darungrim/source/browse/trunk/ExtLib/XGetopt.cpp?r=17 `check.cpp: In function ‘int main()’:` check.cpp:14:55:
I'm calling a java service via its http endpoint (embedded jetty). The service handles

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.