Not enough information to form a hypothesis. However I have a guess. The variable i inside click handler looks very suspicious.
marker.url = '#'+i; Have you made sure that i has a good value at the moment when a click takes place. -- You received this message because you are subscribed to the Google Groups "Google Maps JavaScript API v3" group. To post to this group, send email to google-maps-js-api-v3@googlegroups.com. To unsubscribe from this group, send email to google-maps-js-api-v3+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-maps-js-api-v3?hl=en.