Use simple forms to create attributions in examples

This commit is contained in:
Marc Jansen
2016-03-10 11:14:59 +01:00
parent df4f1c1389
commit 5b43e8a31e
17 changed files with 41 additions and 113 deletions

View File

@@ -21,12 +21,6 @@ for (var z = 0; z < 14; ++z) {
matrixIds[z] = z;
}
var attribution = new ol.Attribution({
html: 'Tiles &copy; <a href="http://services.arcgisonline.com/arcgis/rest/' +
'services/Demographics/USA_Population_Density/MapServer/">ArcGIS</a>'
});
var map = new ol.Map({
layers: [
new ol.layer.Tile({
@@ -36,7 +30,8 @@ var map = new ol.Map({
new ol.layer.Tile({
opacity: 0.7,
source: new ol.source.WMTS({
attributions: [attribution],
attributions: 'Tiles © <a href="http://services.arcgisonline.com/arcgis/rest/' +
'services/Demographics/USA_Population_Density/MapServer/">ArcGIS</a>',
url: 'http://services.arcgisonline.com/arcgis/rest/' +
'services/Demographics/USA_Population_Density/MapServer/WMTS/',
layer: '0',