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 3598694
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T20:16:27+00:00 2026-05-18T20:16:27+00:00

I have something along the lines of: By default all these panels are empty.

  • 0

I have something along the lines of:

By default all these panels are empty. But user actions can populate the panels, and users can switch between panels.

The problem I have right now is that switching between panels keeps refreshing the content from the server, even when it’s already been loaded, which is a slow UI experience.

I was thinking of appending a timestamp to each of the panel divs:

<div id="panel-1" timestamp="13123131313"></div>

And then using that timestamp to determine if I should rehit the server, if it’s under a minute don’t, if over a minute refresh the content.

What I’m looking for:

  1. Your thoughts on this?
  2. Where can I safely store the time stamp?
  3. Suggestions for doing the timestamp comparison. Any simple jQuery solutions?

Thanks for helping me think this one through.

  • 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-18T20:16:27+00:00Added an answer on May 18, 2026 at 8:16 pm

    You could accomplish this easily—with valid markup—using jQuery’s .data() method.

    Something akin to this:

    // store timestamp on initial ajax load
    var timestamp = new Date().getTime();
    $('#panel-1').data('timestamp', timestamp);
    
    // How to retrieve last timestamp
    var last_stamp = $('#panel-1').data('timestamp');
    
    // Example of comparing timestamps and setting a new one
    var new_timestamp = new Date().getTime(),
        last_stamp = $('#panel-1').data('timestamp');
    if (new_timestamp - last_stamp >= 60000) {
        $.ajax({
            /* ajax options */
            success: function() {
                var timestamp = new Date().getTime();
                $('#panel-1').data('timestamp', timestamp);
            }
        });
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have something along the lines of: By default all these panels are empty.
So i have something along the lines of private ObservableCollection<ViewModel> _internal; public ObservableCollection<ViewModel> BoundInternal{get;set};
Say I have something along the lines of: int main() { const char* someString
I have a page using something along the lines of <meta http-equiv=refresh content=0;url=http://example.com/ />
Hi I have an li element that will have something along the lines of
I have something along the lines of.. private UavControlForm() { InitializeComponent(); if (ControlFacade.CheckIfStkIsLaunched()) {
I'm currently writing some code where I have something along the lines of: double
I have something of a logical puzzle I can not figure out. I have
Let's say I have a Generic Repository class along the lines of the following:
I have a tree-like model where in all situations but one , I want

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.