I wonder if anyone can help me find out why my polyline disappears
after zooming right out and back in again? The points remain but the
polyline disappears.
I don't see the points disappear, (Firefox 2), but there is another
problem, and that is that you're asking the browser to do way more
work than necessary.
You're calling the function getAltitude() maxNodes times, and that is
100 times GDownloadUrl()!
You could send all points in one call, as POST data, and get back a
long comma separated string that you split() into an array.Then you're
done with just one GDownloadUrl call.
Other than that, maybe I looked too quickly, but why are you calling
altitude.php if you already have the altitude in the GPX file, in the
field <ele></ele>?
<gor...@vehicletrackingdirect.com> wrote:
> I wonder if anyone can help me find out why my polyline disappears
> after zooming right out and back in again? The points remain but the
> polyline disappears.
> problem, and that is that you're asking the browser to do way more
> work than necessary.
> You're calling the function getAltitude() maxNodes times, and that is
> 100 times GDownloadUrl()!
> You could send all points in one call, as POST data, and get back a
> long comma separated string that you split() into an array.Then you're
> done with just one GDownloadUrl call.
> Other than that, maybe I looked too quickly, but why are you calling
> altitude.php if you already have the altitude in the GPX file, in the
> field <ele></ele>?
> On Oct 23, 8:45 pm, "muirstra...@googlemail.com"
> <gor...@vehicletrackingdirect.com> wrote:
> > I wonder if anyone can help me find out why my polyline disappears
> > after zooming right out and back in again? The points remain but the
> > polyline disappears.
I am using FF 3.5.3 and one of my friends was getting the same problem
using safari, it's weird but if I zoom out and then pan out of view
but then come back the polyline has gone but the points are there (I
know its an issue which is never likely to happen in real life but
wanted to try to get it right)
The reason I don't use the altitude info in the gpx file is that it is
so far from correct it is useless unfortunately.
I'll have a look at my GDownloadUrl call and try to change it although
I am not particularly skilled in javascript but I am trying!
Thanks
Gordon
On Oct 23, 8:03 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > problem, and that is that you're asking the browser to do way more
> > work than necessary.
> > You're calling the function getAltitude() maxNodes times, and that is
> > 100 times GDownloadUrl()!
> > You could send all points in one call, as POST data, and get back a
> > long comma separated string that you split() into an array.Then you're
> > done with just one GDownloadUrl call.
> > Other than that, maybe I looked too quickly, but why are you calling
> > altitude.php if you already have the altitude in the GPX file, in the
> > field <ele></ele>?
> > On Oct 23, 8:45 pm, "muirstra...@googlemail.com"
> > <gor...@vehicletrackingdirect.com> wrote:
> > > I wonder if anyone can help me find out why my polyline disappears
> > > after zooming right out and back in again? The points remain but the
> > > polyline disappears.
Well, I still cannot get the line to disappear, but it could be
because you're making the browser do so much work.
Aside from the 100 calls to altitude.php you are also calling Google
Charts 100 times! That's 200 http requests before your map can render,
where you could be doing the same with just 2 calls.
Try reorganizing the strategy:
-- First read the GPX, and append each lat/lon's to a string with some
separator.
-- When that loop has completed call altitude.php once, with that long
string of lat/lon's as parameter. Use the POST method if the string is
too long.
-- Let PHP split the string into individual points, look up the
altitudes, wherever it does that, and return one long string of
altitudes.
-- Use plain text rather than XML to return results from PHP.
-- Then call Google Charts only once, with that long string of
altitudes.
That's just an overview of a strategy that should allow your page to
load about 100 times faster.
Give it a try and see if the polylines start behaving.
<gor...@vehicletrackingdirect.com> wrote:
> Hi Marcelo
> I am using FF 3.5.3 and one of my friends was getting the same problem
> using safari, it's weird but if I zoom out and then pan out of view
> but then come back the polyline has gone but the points are there (I
> know its an issue which is never likely to happen in real life but
> wanted to try to get it right)
> The reason I don't use the altitude info in the gpx file is that it is
> so far from correct it is useless unfortunately.
> I'll have a look at my GDownloadUrl call and try to change it although
> I am not particularly skilled in javascript but I am trying!
> Thanks
> Gordon
> On Oct 23, 8:03 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > On Oct 23, 9:02 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > > I don't see the points disappear, (Firefox 2),
> > Sorry, I meant I don't see the *polyline* disappear! :-)
> > > problem, and that is that you're asking the browser to do way more
> > > work than necessary.
> > > You're calling the function getAltitude() maxNodes times, and that is
> > > 100 times GDownloadUrl()!
> > > You could send all points in one call, as POST data, and get back a
> > > long comma separated string that you split() into an array.Then you're
> > > done with just one GDownloadUrl call.
> > > Other than that, maybe I looked too quickly, but why are you calling
> > > altitude.php if you already have the altitude in the GPX file, in the
> > > field <ele></ele>?
> > > On Oct 23, 8:45 pm, "muirstra...@googlemail.com"
> > > <gor...@vehicletrackingdirect.com> wrote:
> > > > I wonder if anyone can help me find out why my polyline disappears
> > > > after zooming right out and back in again? The points remain but the
> > > > polyline disappears.
I see your point on the altitude being requested 100 times and if I
get a string back then I will be able to send it without the loop to
get the values for google chart.
However I think I am just sending I call to chart as I really just
send this url
> Well, I still cannot get the line to disappear, but it could be
> because you're making the browser do so much work.
> Aside from the 100 calls to altitude.php you are also calling Google
> Charts 100 times! That's 200 http requests before your map can render,
> where you could be doing the same with just 2 calls.
> Try reorganizing the strategy:
> -- First read the GPX, and append each lat/lon's to a string with some
> separator.
> -- When that loop has completed call altitude.php once, with that long
> string of lat/lon's as parameter. Use the POST method if the string is
> too long.
> -- Let PHP split the string into individual points, look up the
> altitudes, wherever it does that, and return one long string of
> altitudes.
> -- Use plain text rather than XML to return results from PHP.
> -- Then call Google Charts only once, with that long string of
> altitudes.
> That's just an overview of a strategy that should allow your page to
> load about 100 times faster.
> Give it a try and see if the polylines start behaving.
> On Oct 23, 9:27 pm, "muirstra...@googlemail.com"
> <gor...@vehicletrackingdirect.com> wrote:
> > Hi Marcelo
> > I am using FF 3.5.3 and one of my friends was getting the same problem
> > using safari, it's weird but if I zoom out and then pan out of view
> > but then come back the polyline has gone but the points are there (I
> > know its an issue which is never likely to happen in real life but
> > wanted to try to get it right)
> > The reason I don't use the altitude info in the gpx file is that it is
> > so far from correct it is useless unfortunately.
> > I'll have a look at my GDownloadUrl call and try to change it although
> > I am not particularly skilled in javascript but I am trying!
> > Thanks
> > Gordon
> > On Oct 23, 8:03 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > > On Oct 23, 9:02 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > > > I don't see the points disappear, (Firefox 2),
> > > Sorry, I meant I don't see the *polyline* disappear! :-)
> > > > problem, and that is that you're asking the browser to do way more
> > > > work than necessary.
> > > > You're calling the function getAltitude() maxNodes times, and that is
> > > > 100 times GDownloadUrl()!
> > > > You could send all points in one call, as POST data, and get back a
> > > > long comma separated string that you split() into an array.Then you're
> > > > done with just one GDownloadUrl call.
> > > > Other than that, maybe I looked too quickly, but why are you calling
> > > > altitude.php if you already have the altitude in the GPX file, in the
> > > > field <ele></ele>?
> > > > On Oct 23, 8:45 pm, "muirstra...@googlemail.com"
> > > > <gor...@vehicletrackingdirect.com> wrote:
> > > > > I wonder if anyone can help me find out why my polyline disappears
> > > > > after zooming right out and back in again? The points remain but the
> > > > > polyline disappears.
I'm getting a report of this same problem from one of my users who is
on IE7. He says the polyline is disappearing at every other level as
he zooms in or out. I can't reproduce the problem with Firefox or IE8,
but will try it on IE7 this weekend.
<gor...@vehicletrackingdirect.com> wrote:
> Hi Marcelo
> I see your point on the altitude being requested 100 times and if I
> get a string back then I will be able to send it without the loop to
> get the values for google chart.
> However I think I am just sending I call to chart as I really just
> send this url
> I'll certainly have a crack at changing the altitude request method.
> Thanks for your time and help
> Cheers
> Gordon
> On Oct 23, 9:23 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > Well, I still cannot get the line to disappear, but it could be
> > because you're making the browser do so much work.
> > Aside from the 100 calls to altitude.php you are also calling Google
> > Charts 100 times! That's 200 http requests before your map can render,
> > where you could be doing the same with just 2 calls.
> > Try reorganizing the strategy:
> > -- First read the GPX, and append each lat/lon's to a string with some
> > separator.
> > -- When that loop has completed call altitude.php once, with that long
> > string of lat/lon's as parameter. Use the POST method if the string is
> > too long.
> > -- Let PHP split the string into individual points, look up the
> > altitudes, wherever it does that, and return one long string of
> > altitudes.
> > -- Use plain text rather than XML to return results from PHP.
> > -- Then call Google Charts only once, with that long string of
> > altitudes.
> > That's just an overview of a strategy that should allow your page to
> > load about 100 times faster.
> > Give it a try and see if the polylines start behaving.
> > On Oct 23, 9:27 pm, "muirstra...@googlemail.com"
> > <gor...@vehicletrackingdirect.com> wrote:
> > > Hi Marcelo
> > > I am using FF 3.5.3 and one of my friends was getting the same problem
> > > using safari, it's weird but if I zoom out and then pan out of view
> > > but then come back thepolylinehas gone but the points are there (I
> > > know its an issue which is never likely to happen in real life but
> > > wanted to try to get it right)
> > > The reason I don't use the altitude info in the gpx file is that it is
> > > so far from correct it is useless unfortunately.
> > > I'll have a look at my GDownloadUrl call and try to change it although
> > > I am not particularly skilled in javascript but I am trying!
> > > Thanks
> > > Gordon
> > > On Oct 23, 8:03 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > > > On Oct 23, 9:02 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > > > > I don't see the points disappear, (Firefox 2),
> > > > Sorry, I meant I don't see the *polyline* disappear! :-)
> > > > > problem, and that is that you're asking the browser to do way more
> > > > > work than necessary.
> > > > > You're calling the function getAltitude() maxNodes times, and that is
> > > > > 100 times GDownloadUrl()!
> > > > > You could send all points in one call, as POST data, and get back a
> > > > > long comma separated string that you split() into an array.Then you're
> > > > > done with just one GDownloadUrl call.
> > > > > Other than that, maybe I looked too quickly, but why are you calling
> > > > > altitude.php if you already have the altitude in the GPX file, in the
> > > > > field <ele></ele>?
> > > > > On Oct 23, 8:45 pm, "muirstra...@googlemail.com"
> > > > > <gor...@vehicletrackingdirect.com> wrote:
> > > > > > I wonder if anyone can help me find out why mypolylinedisappears
> > > > > > after zooming right out and back in again? The points remain but the
> > > > > >polylinedisappears.
I never really tried for a solution I just took your advice and I am working
on cutting down the work the server has to do hoping that this will cure it.
I tried yours with FF and IE (latest versions) and couldn't get the line to
disappear.
[mailto:google-maps-api@googlegroups.com] On Behalf Of Davepar
Sent: 30 October 2009 15:43
To: Google Maps API
Subject: Re: Disappearing polyline?
I'm getting a report of this same problem from one of my users who is
on IE7. He says the polyline is disappearing at every other level as
he zooms in or out. I can't reproduce the problem with Firefox or IE8,
but will try it on IE7 this weekend.
On Oct 23, 1:35 pm, "muirstra...@googlemail.com"
<gor...@vehicletrackingdirect.com> wrote:
> Hi Marcelo
> I see your point on the altitude being requested 100 times and if I
> get a string back then I will be able to send it without the loop to
> get the values for google chart.
> However I think I am just sending I call to chart as I really just
> send this url
> I'll certainly have a crack at changing the altitude request method.
> Thanks for your time and help
> Cheers
> Gordon
> On Oct 23, 9:23 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > Well, I still cannot get the line to disappear, but it could be
> > because you're making the browser do so much work.
> > Aside from the 100 calls to altitude.php you are also calling Google
> > Charts 100 times! That's 200 http requests before your map can render,
> > where you could be doing the same with just 2 calls.
> > Try reorganizing the strategy:
> > -- First read the GPX, and append each lat/lon's to a string with some
> > separator.
> > -- When that loop has completed call altitude.php once, with that long
> > string of lat/lon's as parameter. Use the POST method if the string is
> > too long.
> > -- Let PHP split the string into individual points, look up the
> > altitudes, wherever it does that, and return one long string of
> > altitudes.
> > -- Use plain text rather than XML to return results from PHP.
> > -- Then call Google Charts only once, with that long string of
> > altitudes.
> > That's just an overview of a strategy that should allow your page to
> > load about 100 times faster.
> > Give it a try and see if the polylines start behaving.
> > On Oct 23, 9:27 pm, "muirstra...@googlemail.com"
> > <gor...@vehicletrackingdirect.com> wrote:
> > > Hi Marcelo
> > > I am using FF 3.5.3 and one of my friends was getting the same problem
> > > using safari, it's weird but if I zoom out and then pan out of view
> > > but then come back thepolylinehas gone but the points are there (I
> > > know its an issue which is never likely to happen in real life but
> > > wanted to try to get it right)
> > > The reason I don't use the altitude info in the gpx file is that it is
> > > so far from correct it is useless unfortunately.
> > > I'll have a look at my GDownloadUrl call and try to change it although
> > > I am not particularly skilled in javascript but I am trying!
> > > Thanks
> > > Gordon
> > > On Oct 23, 8:03 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > > > On Oct 23, 9:02 pm, Marcelo <marcelo...@hotmail.com> wrote:
> > > > > I don't see the points disappear, (Firefox 2),
> > > > Sorry, I meant I don't see the *polyline* disappear! :-)
> > > > > problem, and that is that you're asking the browser to do way more
> > > > > work than necessary.
> > > > > You're calling the function getAltitude() maxNodes times, and that
is
> > > > > 100 times GDownloadUrl()!
> > > > > You could send all points in one call, as POST data, and get back
a
> > > > > long comma separated string that you split() into an array.Then
you're
> > > > > done with just one GDownloadUrl call.
> > > > > Other than that, maybe I looked too quickly, but why are you
calling
> > > > > altitude.php if you already have the altitude in the GPX file, in
the
> > > > > field <ele></ele>?
> > > > > On Oct 23, 8:45 pm, "muirstra...@googlemail.com"
> > > > > <gor...@vehicletrackingdirect.com> wrote:
> > > > > > I wonder if anyone can help me find out why mypolylinedisappears
> > > > > > after zooming right out and back in again? The points remain but
the
> > > > > >polylinedisappears.
Hmm I'm using FF 3.5.4 on Linux (Ubuntu Karmic Koala 9.10) and I don't
see any problem. Polyline and points stay visible for me. I wonder if
it's related to network performance--maybe it fails for those with
slower connections? Maybe Marcelo is on he right track here.
-Brian
On Nov 5, 3:57 am, Dennis <d.goryac...@gmail.com> wrote:
There is relatively simple algorithm for link
http://80.176.208.244/cycle/downloads/1/gmap.php to see how polyline
disappear.
1) Zoom in map to maximum zoomlevel, to see only part of line.
2) Drag map along line, 5-6 times for me
3) Polyline disappears, but markers still visible
4) Zoom out map - no polyline at all :(
Tested in
1) Opera/9.80 (X11; Linux x86_64; U; en) Presto/2.2.15 Version/10.00
2) Mozilla/5.0 (X11; U; Linux i686 (x86_64); ru; rv:1.9.1.4) Gecko/20091016
Firefox/3.5.4
3) Mozilla/5.0 (compatible; Konqueror/4.3; Linux) KHTML/4.3.3 (like Gecko)
I have same bug on my own pages, under certain conditions, but I can't make
test page now. Definitly it's not related with network performance, since i
see this bug only under certain conditions, and can bypass it, changing
scripts
On Fri, Nov 6, 2009 at 6:27 PM, Brian P <brianpey...@gmail.com> wrote:
> Hmm I'm using FF 3.5.4 on Linux (Ubuntu Karmic Koala 9.10) and I don't
> see any problem. Polyline and points stay visible for me. I wonder if
> it's related to network performance--maybe it fails for those with
> slower connections? Maybe Marcelo is on he right track here.
> You received this message because you are subscribed to the Google Groups
> "Google Maps API" group.
> To post to this group, send email to google-maps-api@googlegroups.com.
> To unsubscribe from this group, send email to
> google-maps-api+unsubscribe@googlegroups.com<google-maps-api%2Bunsubscribe@ googlegroups.com>
> .
> For more options, visit this group at
> http://groups.google.com/group/google-maps-api?hl=en.