From codebowl at gmail.com Wed Feb 28 17:49:05 2007 From: codebowl at gmail.com (Joseph Crawford) Date: Tue Mar 4 07:24:11 2008 Subject: [front-end] Google Maps API Message-ID: <8d9a42800702281449v33deb86aoe4ec89e665902492@mail.gmail.com> Anyone have any idea why this is not working? /* snip */ for (i in points) { var point = new GLatLng(points[i].lat,points[i].lng); var marker = createMarker(point, points[i].type, points[i].name); map.addOverlay(marker); } /* snip */ function createMarker(point, type, name) { //create the marker with the appropriate icon if(type=='c') { var marker = new GMarker(point,iconCluster,true); GEvent.addListener(marker, "click", function() { marker.openInfoWindowHtml(name); }); } else { var marker = new GMarker(point,iconSingle,true); GEvent.addListener(marker, "click", function() { marker.openInfoWindowHtml(name); }); } return marker; } When i load the map and click on a marker (either cluster or single) it does not show the information window like it should. I am using some Server Side Clustering code found in the book Beginning Google Maps Applications with PHP and Ajax (ISBN: 1590597079) Any help would be appreciated, you can see the live sample on http://codebowl.homeip.net/eremaps/ Thanks, -- Joseph Crawford Jr. Zend Certified Engineer Codebowl Solutions, Inc. http://www.codebowl.com/ Blog: http://www.josephcrawford.com/ 1-802-671-2021 codebowl@gmail.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.lists.nyphp.org/pipermail/front-end/attachments/20070228/12b9ac31/attachment.html From codebowl at gmail.com Wed Feb 28 17:52:25 2007 From: codebowl at gmail.com (Joseph Crawford) Date: Tue Mar 4 07:24:11 2008 Subject: [front-end] Re: Google Maps API In-Reply-To: <8d9a42800702281449v33deb86aoe4ec89e665902492@mail.gmail.com> References: <8d9a42800702281449v33deb86aoe4ec89e665902492@mail.gmail.com> Message-ID: <8d9a42800702281452k2129e65rf3063ee7dfcd0dc7@mail.gmail.com> Please ignore this, i see that it is due to the inert being set to true. Thanks, -- Joseph Crawford Jr. Zend Certified Engineer Codebowl Solutions, Inc. http://www.codebowl.com/ Blog: http://www.josephcrawford.com/ 1-802-671-2021 codebowl@gmail.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.lists.nyphp.org/pipermail/front-end/attachments/20070228/68d86c0f/attachment.html From chsnyder at gmail.com Wed Feb 28 20:19:40 2007 From: chsnyder at gmail.com (csnyder) Date: Tue Mar 4 07:24:11 2008 Subject: [front-end] Google Maps API In-Reply-To: <8d9a42800702281449v33deb86aoe4ec89e665902492@mail.gmail.com> References: <8d9a42800702281449v33deb86aoe4ec89e665902492@mail.gmail.com> Message-ID: On 2/28/07, Joseph Crawford wrote: > var marker = new GMarker(point,iconCluster,true); That is some mad clustering! I had no idea you could do that. From 1j0lkq002 at sneakemail.com Wed Feb 28 20:51:12 2007 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Tue Mar 4 07:24:11 2008 Subject: [front-end] Google Maps API In-Reply-To: <8d9a42800702281449v33deb86aoe4ec89e665902492@mail.gmail.com> References: <8d9a42800702281449v33deb86aoe4ec89e665902492@mail.gmail.com> Message-ID: <17023-34469@sneakemail.com> Joseph Crawford codebowl-at-gmail.com |nyphp dev/internal group use| wrote: > Anyone have any idea why this is not working? > >/* snip */ >for (i in points) { > var point = new GLatLng(points[i].lat,points[i].lng); > var marker = createMarker(point, points[i].type, points[i].name); > > map.addOverlay(marker); >} > >/* snip */ >function createMarker(point, type, name) { > //create the marker with the appropriate icon > if(type=='c') { > var marker = new GMarker(point,iconCluster,true); > > GEvent.addListener(marker, "click", function() { > marker.openInfoWindowHtml(name); > }); > } else { > var marker = new GMarker(point,iconSingle,true); > >GEvent.addListener(marker, "click", function() { > marker.openInfoWindowHtml(name); > }); > } > return marker; >} > > > When i load the map and click on a marker (either cluster or single) > it does not show the information window like it should. > I am using some Server Side Clustering code found in the book > Beginning Google Maps Applications with PHP and Ajax (ISBN: 1590597079) > > Any help would be appreciated, you can see the live sample on > http://codebowl.homeip.net/eremaps/ > joe, If you drill down there is still some work to do. I looked at Univ Washington in Seattle where there is a cluster of 6, and I drilled down to see a cluster of one. Backing off on level at a time looking for the other 5 doesn't yield them... you get back to a cluster of 6 before you find the other five. Are you counting individuals by address so 6 people may have the same university address? -=john -- ------------------------------------------------------------- Your web server traffic log file is the most important source of web business information available. Do you know where your logs are right now? Do you know who else has access to your log files? When they were last archived? Where those archives are? --John Andrews Competitive Webmaster and SEO Blogging at http://www.johnon.com From codebowl at gmail.com Wed Feb 28 23:21:07 2007 From: codebowl at gmail.com (Joseph Crawford) Date: Tue Mar 4 07:24:11 2008 Subject: [front-end] Google Maps API In-Reply-To: <17023-34469@sneakemail.com> References: <8d9a42800702281449v33deb86aoe4ec89e665902492@mail.gmail.com> <17023-34469@sneakemail.com> Message-ID: <8d9a42800702282021x4450b66fk5c0059606437a355@mail.gmail.com> I found what is happening is that you will see 6 clusters on the screen each will say there are 6 points under the cluster when in fact there are only 6 points total, some reason it is making each point a cluster when there are more than 5 points on the screen. I need to dig down into that. I also need to know how to pass a value from JS to PHP so that i can do map.getZoom() and use the value in PHP any ideas? -- Joseph Crawford Jr. Zend Certified Engineer Codebowl Solutions, Inc. http://www.codebowl.com/ Blog: http://www.josephcrawford.com/ 1-802-671-2021 codebowl@gmail.com -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.lists.nyphp.org/pipermail/front-end/attachments/20070228/04782c03/attachment.html