Skip to main content
deleted 1 character in body
Source Link
jmarr
  • 23
  • 3

The qgis2web plugin exports complete rasters. But in my case these files are too large... so instead of using the entire layer I'd like to use a tiled layer that I created (with TileMill).

What would be the best way to do this? I thought of a few ideas, but being a beginner in JS I couldn't get it to work:

  1. Insert the ol.layer.Tile + view: new ol.View code in the index.html?
  2. Insert the above codes in the qgis2web.js file (I suspect this is the right way but couldn't get it to work).
  3. Is it possible to add the tile layer as a separate .js file and launch it from index.html?
  4. I also assume I have to change the background color of the map in index.html to be transparent.

The zipfile of the qgis2web output (with only two small vector layers, 200KB) can be downloaded from:

http://www.tempgis.com.au/wp-content/uploads/stackexch/ol_qgis2web.zip

The link to one of the XYZ tiled images is:

http://www.tempgis.com.au/wp-content/uploads/stackexch/regional/{z}/{x}/{y}.png'http://www.tempgis.com.au/wp-content/uploads/stackexch/regional/{z}/{x}/{y}.png

The qgis2web plugin exports complete rasters. But in my case these files are too large... so instead of using the entire layer I'd like to use a tiled layer that I created (with TileMill).

What would be the best way to do this? I thought of a few ideas, but being a beginner in JS I couldn't get it to work:

  1. Insert the ol.layer.Tile + view: new ol.View code in the index.html?
  2. Insert the above codes in the qgis2web.js file (I suspect this is the right way but couldn't get it to work).
  3. Is it possible to add the tile layer as a separate .js file and launch it from index.html?
  4. I also assume I have to change the background color of the map in index.html to be transparent.

The zipfile of the qgis2web output (with only two small vector layers, 200KB) can be downloaded from:

http://www.tempgis.com.au/wp-content/uploads/stackexch/ol_qgis2web.zip

The link to one of the XYZ tiled images is:

http://www.tempgis.com.au/wp-content/uploads/stackexch/regional/{z}/{x}/{y}.png'

The qgis2web plugin exports complete rasters. But in my case these files are too large... so instead of using the entire layer I'd like to use a tiled layer that I created (with TileMill).

What would be the best way to do this? I thought of a few ideas, but being a beginner in JS I couldn't get it to work:

  1. Insert the ol.layer.Tile + view: new ol.View code in the index.html?
  2. Insert the above codes in the qgis2web.js file (I suspect this is the right way but couldn't get it to work).
  3. Is it possible to add the tile layer as a separate .js file and launch it from index.html?
  4. I also assume I have to change the background color of the map in index.html to be transparent.

The zipfile of the qgis2web output (with only two small vector layers, 200KB) can be downloaded from:

http://www.tempgis.com.au/wp-content/uploads/stackexch/ol_qgis2web.zip

The link to one of the XYZ tiled images is:

http://www.tempgis.com.au/wp-content/uploads/stackexch/regional/{z}/{x}/{y}.png

deleted 63 characters in body; edited tags
Source Link
PolyGeo
  • 65.4k
  • 29
  • 114
  • 345

The qgis2web plugin exports complete rasters. But in my case these files are too large... so instead of using the entire layer I'd like to use a tiled layer that I created (with TileMill).

What would be the best way to do this? I thought of a few ideas, but being a beginner in JS I couldn't get it to work:

  1. Insert the ol.layer.Tile + view: new ol.View code in the index.html?
  2. Insert the above codes in the qgis2web.js file (I suspect this is the right way but couldn't get it to work).
  3. Is it possible to add the tile layer as a separate .js file and launch it from index.html?
  4. I also assume I have to change the background color of the map in index.html to be transparent.

The zipfile of the qgis2web output (with only two small vector layers, 200KB) can be downloaded from:

http://www.tempgis.com.au/wp-content/uploads/stackexch/ol_qgis2web.zip

The link to one of the XYZ tiled images is:

http://www.tempgis.com.au/wp-content/uploads/stackexch/regional/{z}/{x}/{y}.png'

Any help and suggestions would be much appreciated. Thanks!

The qgis2web plugin exports complete rasters. But in my case these files are too large... so instead of using the entire layer I'd like to use a tiled layer that I created (with TileMill).

What would be the best way to do this? I thought of a few ideas, but being a beginner in JS I couldn't get it to work:

  1. Insert the ol.layer.Tile + view: new ol.View code in the index.html?
  2. Insert the above codes in the qgis2web.js file (I suspect this is the right way but couldn't get it to work).
  3. Is it possible to add the tile layer as a separate .js file and launch it from index.html?
  4. I also assume I have to change the background color of the map in index.html to be transparent.

The zipfile of the qgis2web output (with only two small vector layers, 200KB) can be downloaded from:

http://www.tempgis.com.au/wp-content/uploads/stackexch/ol_qgis2web.zip

The link to one of the XYZ tiled images is:

http://www.tempgis.com.au/wp-content/uploads/stackexch/regional/{z}/{x}/{y}.png'

Any help and suggestions would be much appreciated. Thanks!

The qgis2web plugin exports complete rasters. But in my case these files are too large... so instead of using the entire layer I'd like to use a tiled layer that I created (with TileMill).

What would be the best way to do this? I thought of a few ideas, but being a beginner in JS I couldn't get it to work:

  1. Insert the ol.layer.Tile + view: new ol.View code in the index.html?
  2. Insert the above codes in the qgis2web.js file (I suspect this is the right way but couldn't get it to work).
  3. Is it possible to add the tile layer as a separate .js file and launch it from index.html?
  4. I also assume I have to change the background color of the map in index.html to be transparent.

The zipfile of the qgis2web output (with only two small vector layers, 200KB) can be downloaded from:

http://www.tempgis.com.au/wp-content/uploads/stackexch/ol_qgis2web.zip

The link to one of the XYZ tiled images is:

http://www.tempgis.com.au/wp-content/uploads/stackexch/regional/{z}/{x}/{y}.png'

Source Link
jmarr
  • 23
  • 3

Is it possible to insert an XYZ tile layer to an openlayers webmap created by qgis2web plugin?

The qgis2web plugin exports complete rasters. But in my case these files are too large... so instead of using the entire layer I'd like to use a tiled layer that I created (with TileMill).

What would be the best way to do this? I thought of a few ideas, but being a beginner in JS I couldn't get it to work:

  1. Insert the ol.layer.Tile + view: new ol.View code in the index.html?
  2. Insert the above codes in the qgis2web.js file (I suspect this is the right way but couldn't get it to work).
  3. Is it possible to add the tile layer as a separate .js file and launch it from index.html?
  4. I also assume I have to change the background color of the map in index.html to be transparent.

The zipfile of the qgis2web output (with only two small vector layers, 200KB) can be downloaded from:

http://www.tempgis.com.au/wp-content/uploads/stackexch/ol_qgis2web.zip

The link to one of the XYZ tiled images is:

http://www.tempgis.com.au/wp-content/uploads/stackexch/regional/{z}/{x}/{y}.png'

Any help and suggestions would be much appreciated. Thanks!