3

Can we use third party base map (images tiles) for displaying vector data?, like we use google map as base layer for displaying vector data in OpenLayers application.

4

Yes. You need to connect to a web map service (WMS) or web feature service (WFS). Have a look here for a few. You need to watch the licencing though. For instance, OSM are happy for you to use their data and even their servers but you can't use their servers for heavy (commercial use). You can also render your own layers. You can also connect to Google and use Google base maps in OpenLayers. You just need to import the Google API at the start of your JavaScript.

There is a lot of advice on how to do this in this forum.

2

I just worked through some of the details to show google basemaps in the JSAPI. You can see a working example here. The majority of the code is posted on questions/20766. ESRI JSAPI example for OSM can be found here but this should get you started:

Required the osm package:

dojo.require( "esri.layers.osm" )

Create the layer:

osmLayer = new esri.layers.OpenStreetMapLayer( options );

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.