display truck attributes layer with leaflet

This forum covers all questions dealing with visualization of data within the native PTV xMap interface. Please remember that additional plugins such as AJAX or Leaflet may be handeled in other forums.
Post Reply
User avatar
loic.caouen
Posts: 8
Joined: Mon Dec 17, 2018 3:37 pm

display truck attributes layer with leaflet

Post by loic.caouen »

Is there a simple a way to display truck attributes layer with leaflet on xMap 1 ?

With xMap 2 we just need this:

Code: Select all

	tileUrl = "http://xserver-2:50000/services/rest/XMap/tile/{z}/{x}/{y}?storedProfile=default&layers=PTV_TruckAttributes";
	new L.TileLayer(tileUrl, { minZoom: 1, maxZoom: 19 }).addTo(map);
Can we do the same with xMap 1?
Loïc Caouën
Technical Consultant
PTV FRANCE
Joost
Posts: 307
Joined: Fri Apr 25, 2014 1:46 pm

Re: display truck attributes layer with leaflet

Post by Joost »

You need to configure the Featurelayer via snippet and add that to the layer requests. Have a look at https://svc-eu-n-test.cloud.ptvgroup.co ... flet/split for a working sample.
Joost Claessen
Senior Technical Consultant
PTV Benelux
User avatar
loic.caouen
Posts: 8
Joined: Mon Dec 17, 2018 3:37 pm

Re: display truck attributes layer with leaflet

Post by loic.caouen »

Thanks for your help Joost.
I've found in the sample what I needed !
Loïc Caouën
Technical Consultant
PTV FRANCE
Post Reply