No I believe I see where the problem is. So as the variables kiev ...etc. are undefined the array with them is in fact empty... So. I need to define variables first and only than collect them into array... Than the question is... how to tell to array cities in gmap_loop.js that it should collect only those variable that are equal to names of cities defined in PHP array $clean_cities?
On 10 Грд, 13:36, Rossko <[email protected]> wrote: > > It is commented now to show how it should work. > > If I uncomment it and delete the mannually written array cities in > > gmap_loop.js - nothing works and even begins to tell what guys written > > above like "places.length is null" etc. > > It's very difficult to debug or even tell what you are trying to > achieve while you won't show us the problem version. > > Do you realise that on the main webpage you have some script that > would define an array of undefined variables? > //var cities = new Array(kiev,kharkov,lvov,odessa); > would be run long before you have defined any variable called 'kiev' > etc. > That would get defined later in gmap_loop.js after the page onload > event... -- 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 [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-maps-js-api-v3?hl=en.
