request - load spot data from "other" source

  • I think it would be good if we could setup the map plugin so that spot data could be located in a separate location... such as a different xml file or data node.

    I've played around with trying a simple <includeurl ="spotdata.xml" /> within the googlemap plugin structure... but it looks like it's ignored.

    The concept would allow large amounts of map data to be split up over different files and loaded as needed... similar in idea to being able to specify at what zoom levels a spot shows up at... but more friendly to large amounts of data... of course, this would mean we'd have to be able to "reload" the map plugin and specify the new spot data as needed.

    Graydon

  • Hi,

    normally it should be possible to put the spots in a external xml and include it,
    be sure that there are not additional tags around the <spots>, then it should work,

    e.g.

    map:

    Code
    <plugin ....>
       <include url="spots.xml" />
       ...
    </plugin>

    spots.xml:

    Code
    <spot ... />
    <spot ... />

    best regards,
    Klaus

  • OK... that did it... *rolleyes*

    I'd left the <krpano version... > </krpano> within the xml file.

    In all other cases where I've used the includeurl, the <krpano> elements seemed to be ignored, or skipped over... so I didn't even think to remove that for this... should they NOT be there in all of the other cases as well?

    Thank you

  • I've been playing around with some different configurations for my map and spot points... and I can figure out a long way of doing what I'd want... but wished there was a shorter way.

    Somewhere on the googlemap plugin development (and associated image map plugin) I believe it would be good to be able to set the spot(s) information as an "attribute" instead of a series of subnodes.... with similar structure as the textfield plugin's html / css attributes.

    In the textfield plugin, you can set html="data:htmldata" (same for css) and this allows you to set / change the html data source through an action (i.e. set(plugin[textfield].html,htmldata2) )

    Two examples of how I'm looking at using this...

    1. I've got a small park that's ~300 acres... on initial load, I'd like the spot data to be for general areas around the park. The park also has numerous hiking / biking trails... and I'd like the user to be able to click on a trail "start point" and have a new set of spot data loaded that is specific to that trail... and when needed, go back to the overview set of general spots.

    2. Now we'll look at a large mixed-use development (shopping center) and apply the same concept... one set of data for the general grounds and area... other sets of data for specific areas.

    The same concept could be applied to different situations.

    I know previously I asked about spots being visible at different zoom levels... and I think that is still a good feature to add... but it wouldn't work in the scenarios I provided because the zoom level would be identical (especially in the park sample with some of the trails being pretty long).

    It's not a "show-stopper"... because I know I can remove the map plugin and then load map2 plugin when i go to a different area... but... it's just a longer more intricate process.

    Thanks for the consideration.

    Graydon

  • Hi,

    there is also an additional way:

    you can use actions to change dynamically a set of spots,
    e.g.

  • yeah... that does the trick... now if I could just setup something that took my kml file and pre-populated my addspot(...) *g*

    ... but for now, just need to work on content structure.

    edited and added...

    when adding new spots via "addspot"... also need to use the updatespots() function at the end of the action.

    *thumbup*

    Thanks

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!