Solved

Continuous update/refresh for Google maps - can this be done?

Posted on 2006-10-21
4
366 Views
Last Modified: 2011-10-03
I am trying to build a vehicle tracking system.  It will comprise of:

1) XML file with GPS Coordinates
2) HTML document with Javascipt in order to link in with Google Maps API
3) XSLT document to get xml content into the appropraite format in html document

I have written a separate program in Delphi.  This will automatically update the xml file with the current coordinates of the vehicle.  This will update the XML file every 30 seconds.

It is all working at the moment, but in order for me to see the changing coordinates of the vehicle (remember that the xml file is being updated every 30 seconds) then i have to load the xml file and refresh the cache.  I can't simply just refresh the html page as this just refreshes the html data.

Does anyone know of a way to have the xml data feed into the html document and continuously update the map that is being displayed?  If this can be done without requiring the user to refresh anything (html or xml) then this would be the perfect solution.

Thanks in advance.
0
Comment
Question by:alanrogerson2
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 33

Accepted Solution

by:
shalomc earned 250 total points
ID: 17782090
you have to set a timer in javascript and use the xmlhttprequest method to get an updated copy of the xml file.

see how google do this in gmail.

ShalomC
0
 
LVL 16

Assisted Solution

by:ellandrd
ellandrd earned 250 total points
ID: 17784407
0
 

Author Comment

by:alanrogerson2
ID: 17817928
I used AJAX but stil had the caching problem.  I ended up loading the xml file with a random number parameter at the end of the URI.  This seems like a bit of a cheat to me but it works.  

Thanks for all your help.
0
 
LVL 16

Expert Comment

by:ellandrd
ID: 17817970
>>bit of a cheat

never ;-)

thanks for the points

Ellandrd
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Developer portfolios can be a bit of an enigma—how do you present yourself to employers without burying them in lines of code?  A modern portfolio is more than just work samples, it’s also a statement of how you work.
Color can increase conversions, create feelings of warmth or even incite people to get behind a cause. If you want your website to really impact site visitors, then it is vital to consider the impact color has on them.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question