Convert WMTS examples to strapless template

This commit is contained in:
Tim Schaub
2015-11-17 10:02:10 -07:00
parent a94a00de1d
commit c463321643
10 changed files with 40 additions and 65 deletions

View File

@@ -23,8 +23,10 @@ var map = new ol.Map({
})
});
$.ajax(capabilitiesUrl).then(function(response) {
var result = new ol.format.WMTSCapabilities().read(response);
fetch(capabilitiesUrl).then(function(response) {
return response.text();
}).then(function(text) {
var result = new ol.format.WMTSCapabilities().read(text);
var options = ol.source.WMTS.optionsFromCapabilities(result, {
layer: layer,
matrixSet: 'google3857',