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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T14:00:02+00:00 2026-06-05T14:00:02+00:00

I am developing a site using Silverstripe, and a part of the site requires

  • 0

I am developing a site using Silverstripe, and a part of the site requires an interactive map similar to this – http://www.straytravel.asia/south-east-asia-bus-travel/

I am currently using AJAX to access all the information for each object (which includes, days, price, pass name etc) which changes onmouseover which works fine however load becomes an issue when browsing multiple items.

I would like to store the information for each pass locally which would allow me to retrieve the information faster. I haven’t used JSON in a project and I am wondering if it is the best solution. I am currently able to retrieve all the pass information as JSON objects but I get stuck on how I should use it. Is it a good idea to store as a javascript variable and access the information via some jQuery calls or should I be approaching this problem differently? Does anyone have any good examples I can work off?

Thanks

  • 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-06-05T14:00:06+00:00Added an answer on June 5, 2026 at 2:00 pm

    JSON as a message format is the defacto standard for AJAX. It’s more concise and readily parsed into JavaScript objects, and jQuery works with it very well (for example, using .ajax and setting the dataType to “json” will instruct jQuery to attempt to automatically parse resulting messages into objects from JSON).

    Once you receive a JSON message and parse it into objects, “storage” is subjective. If you are merely keeping reference to the objects you’ve already downloaded to avoid downloading them again, you may simply have a map object to lookup and keep reference.

    Assuming you are looking up info using some identifier, here’s a rough example:

    var infocache = {}; // keeps copy of previously retrieved info messages
    
    function displayInfo(infoId) { // called when you want to display info, using some identifier
       var callback = function() {
           var info = infocache[infoId];
    
           // do something with your info object... display in HTML template or whatever.
       };
    
       if (infocache[infoId]) { 
         callback();
         return;
       }
    
       $.ajax({
          url:'/myapi/info/get', 
          data: {id: infoId }, 
          dataType:'json', 
          type:'POST', 
          success: function(result) {
                 infocache[infoId] = result;
                 callback();
               }
         }); 
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am currently developing a site using SSL that requires users to be able
I am developing a web site using the Zend Framework. I was using this
I am developing a web site using ASP.NET MVC. The site will be similar
So im currently developing this site: http://remedia-solutions.com/clientes/0039_kiplingmexico/demo2/ its almost done but im currently having
I am currently developing a site using ASP.NET MVC 3, I am using Nhibernate.
I'm developing a site using the CakePHP framework. I have a form which shows
I'm currently developing a site using the WordPress Twenty Eleven theme and I would
I am developing a site using asp.net MVC. I have used AJAX for paging,sorting
I'm developing a Web Site using ASP.NET MVC 3, Nowadays I need to encrypt
I'm developing a mobile site using IUI . It's a framework that makes web

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.