Page 3 of 4 FirstFirst 1234 LastLast
Results 31 to 45 of 47
  1. #31
    Lounger
    Join Date
    Apr 2008
    Location
    Colchester, Essex, United Kingdom
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update Google Earth KLM file in real time (200

    Hi John,

    ref your post 710-692 I'm using the page you supplied as the starting page i.e. "use my form at " http://www11.asphost4free.com/GlobalTracker/submit.html

    I've not edited Index ~ should I have made the changes there, was submit.html simply a (working) example? I've also moved your download code from submit to the results page.

    Regards Paul

  2. #32
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Update Google Earth KLM file in real time (200

    OK The mistake was just a typo.

    When you added the Yearofbirth, you wrote Request.From rather than Request.Form in Tracking.asp

    John
    Regards
    John



  3. #33
    Lounger
    Join Date
    Apr 2008
    Location
    Colchester, Essex, United Kingdom
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update Google Earth KLM file in real time (200

    Thanks John, I spent AGES looking at the changes ~ I guess you just become blind to your own stupidity!

  4. #34
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Update Google Earth KLM file in real time (200

    For some reason it is MUCH easier to see typos in other people's work than in your own.

    (Have I just corrected all the ones I just made in typing this? I hope so!)
    Regards
    John



  5. #35
    Lounger
    Join Date
    Apr 2008
    Location
    Colchester, Essex, United Kingdom
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update Google Earth KLM file in real time (200

    Hi John,

    Thanks for that ~ all back on track.

    1) Should I delete index.asp and rename submit.html as index.asp?

    2) Currently Submit saves the data and then downloads the KLM file. I would prefer it to save the data and open result.html (and not download anything) ~ I can't see where to do that?

    3) As you can see I've moved your "download the KLM file) option to the results page. Thats great, What I would also like the results page to do is show the results on the map thats on the page (ie assume the users do not have google earth and show them somethnig on-line). Really ideal woould be to use the timestamp to show the results as they come in

    1 and 2 should be easy, is 3 a step too far? <img src=/S/smile.gif border=0 alt=smile width=15 height=15>

    Research:

    http://code.google.com/apis/kml/docu...kmlSearch.html
    http://code.google.com/apis/maps/documenta...ml#XML_Requests
    http://code.google.com/apis/kml/documentat...l#timeprimitive

  6. #36
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Update Google Earth KLM file in real time (200

    Hi Paul

    1: Yes

    2: I have done this removing the second half of tracking.asp and just replacing it with : Response.Redirect "result.html"

    3: That is (for me) the hard one. The map can't show the locations while they are just sitting in a database on your server somewhere. The original solution displayed them by sending them back to the user's computer as a KML file. Can you send the user's a file and have it displayed on a Google Map? I don't know? Is there anywhere else you can send it? I don't know.

    What do you want to do with the Timestamp ? attach the date/time to each point as a caption?

    I will read the links you provided and see what I can find out.
    Regards
    John



  7. #37
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Update Google Earth KLM file in real time (200

    Just another nitpicking comment.

    You can't open result.html without downloading it! Everything you do on the web involves a download.
    So your desire to " (and not download anything) " is impossible.
    Regards
    John



  8. #38
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Update Google Earth KLM file in real time (200

    The second of links you provided provides a clue on how to do what you want.

    Instead of using a KML file, the contents of the database would need to be written to an XML file on the server (data.xml).

    Then in results.html you would have to include code starting with:

    GDownloadUrl("data.xml", function(data, responseCode)

    that would download the newly created xml file, and display the points on the map the user is looking at.

    I think this download would be invisible to the user.

    I will try to do some more on this, but not now as it is very late here now.
    Attached Images Attached Images
    Regards
    John



  9. #39
    Lounger
    Join Date
    Apr 2008
    Location
    Colchester, Essex, United Kingdom
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update Google Earth KLM file in real time (200

    OK, I've amended those files so submit no longer exists and Index.asp is now the old submit.html (back to testing then :-) ).

    Note your change to Tracking.asp ~ thanks. (Wish I spoke ASP!)

    re nit-picking (by all means pick nits, its better than working) I didn't really mean download "anything" I meant don't download a KLM file automatically :-)

    Re option 3; Its probable we need to write a KLM style file to an online location (perhaps set the data base to write on the hour if anything has changed so save over-writing the file) in the KLM format and then read that data as part of loading the map ~ I'm also researching, however, like Homer, everytime I add some new knowledge some old knowledge falls out of my brain and this is extending me more than a little. :-)

    NB Although I am happy to have instant responses, please dont knock yourself out. There is no hard deadline, it will finish when we have finished. Regards Paul

  10. #40
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Update Google Earth KLM file in real time (200

    I thought you could change tracking.asp, so that after it adds the entry to the db, it then creates a new xml file.

    The code for this would be very similar to code the previously created the KML file. But it would not send it anywhere, just leave it on the server.
    Regards
    John



  11. #41
    Lounger
    Join Date
    Apr 2008
    Location
    Colchester, Essex, United Kingdom
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update Google Earth KLM file in real time (200

    You mean just build the XML file as you go rather then create it from scratch each time ~ that sounds like a good idea as long as it would not be swamped with a rush of entries. (I'm an optimist :-) )

  12. #42
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Update Google Earth KLM file in real time (200

    I think the easiest thing is recreate the whole XML file each time a new record is added to the database.
    The structure of the XML file is such that new records don't go on the end, but near the end. So adding data to an existing XML file would be messy.

    I would be amazed if you get so much traffic that this causes a problem.

    I have put a little file writefile.asp to test the process of writing to a file on a webserver. It works OK for me using the webserver running on my own pc, but it does not work on your site, or any other site I have tried. I think it is a permissions problem.

    I attach a copy as a text file.
    Attached Files Attached Files
    Regards
    John



  13. #43
    Lounger
    Join Date
    Apr 2008
    Location
    Colchester, Essex, United Kingdom
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update Google Earth KLM file in real time (200

    Hi John, There is no premission control on freeasp that I can find (and they are hopeless at returning e-mails ~ I guess pay 'free' and that the service you get). If you can't get it to work on other online sites (where I'm guessing you do have access to permissions) I guess we are stuck?

    I get "The page cannot be displayed" when I try to run writefile.asp Regards Paul

  14. #44
    Super Moderator
    Join Date
    Jun 2002
    Location
    Mt Macedon, Victoria, Australia
    Posts
    3,993
    Thanks
    1
    Thanked 45 Times in 44 Posts

    Re: Update Google Earth KLM file in real time (200

    I have now got it working on a site, where I have figured out the correct permissions.

    But if your site does not allow permissions to be changed I don't what to do.

    There is another issue as well. On your site the error was occurring at different line, from the one I was getting. According to one of my books, the stuff needed to write files to the server is optional, and it may not even be installed on your server.

    You might need to look for a better host.

    In the meantime we can still look at the how to use the XML file in conjunction with Google maps.
    Regards
    John



  15. #45
    Lounger
    Join Date
    Apr 2008
    Location
    Colchester, Essex, United Kingdom
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update Google Earth KLM file in real time (200

    Hi John, Yeah ~ I may even have to pay! (good grief!!) Do you have one you'd recommend (with the facilities you need?) or shall I just take pot luck? Paul

Page 3 of 4 FirstFirst 1234 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •