<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /></head><body style='font-size: 10pt; font-family: Verdana,Geneva,sans-serif'>
<p>Hi Julierme,</p>
<p>The GetProjectSettings XML response provides an element called <span><LayerDrawingOrder/</span><span>> where you can find the initial layer order of the QGIS project. Based on this, you can then formulate the </span>GetMap request with the "LAYERS" parameter. The order you specify after LAYERS= defines the layer rendering order.</p>
<p>Greetings,</p>
<p>Andreas</p>
<p id="reply-intro">On 2021-03-31 22:16, 1520 gis wrote:</p>
<blockquote type="cite" style="padding: 0 0.4em; border-left: #1010ff 2px solid; margin: 0">
<div id="replybody1">
<div>
<div dir="ltr">Hi Andrea,
<div> </div>
<div>Did  you mean to add [1] LAYERDRAWINGORDER=... as a parameter in WMS request?</div>
<div> </div>
<div> [1]  <span class="v1gmail-html-tag" style="color: #000000; font-family: monospace; font-size: 13px;"><LayerDrawingOrder></span><span style="color: #000000; font-family: monospace; font-size: 13px;">OSM,biomas,ufe,rodovias,aerovias,rbmc,maregrafos,cbers4</span><span class="v1gmail-html-tag" style="color: #000000; font-family: monospace; font-size: 13px;"></LayerDrawingOrder></span></div>
<div><span class="v1gmail-html-tag" style="color: #000000; font-family: monospace; font-size: 13px;"> </span></div>
<div><span class="v1gmail-html-tag" style="color: #000000; font-family: monospace; font-size: 13px;">Kind regards</span></div>
<div><span class="v1gmail-html-tag" style="color: #000000; font-family: monospace; font-size: 13px;"> </span></div>
<div><span class="v1gmail-html-tag" style="color: #000000; font-family: monospace; font-size: 13px;">Julierme</span></div>
</div>
<br />
<div class="v1gmail_quote">
<div class="v1gmail_attr" dir="ltr">On Wed, Mar 31, 2021 at 2:13 PM 1520 gis <<a href="mailto:juliermeopensourcedeveloper@gmail.com" rel="noreferrer">juliermeopensourcedeveloper@gmail.com</a>> wrote:</div>
<blockquote class="v1gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left: 1px solid #cccccc; padding-left: 1ex;">
<div dir="ltr">Hi Andreas,
<div> </div>
<div>Thank you very much for your reply and help.</div>
<div> </div>
<div>I appreciate it.</div>
<div> </div>
<div>Kind regards</div>
<div> </div>
<div>Julierme</div>
</div>
<br />
<div class="v1gmail_quote">
<div class="v1gmail_attr" dir="ltr">On Wed, Mar 31, 2021 at 1:17 PM Andreas Neumann <<a href="mailto:a.neumann@carto.net" rel="noreferrer">a.neumann@carto.net</a>> wrote:</div>
<blockquote class="v1gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left: 1px solid #cccccc; padding-left: 1ex;">
<div style="font-size: 10pt; font-family: Verdana,Geneva,sans-serif;">
<p>Hi Julierme,</p>
<p>It is the client that requests a certain layer order, not the server. Unless you request a group layer/top level layer.</p>
<p>You find the information on the initial layer order in the GetProjectSettings response: <a href="https://docs.qgis.org/3.16/en/docs/server_manual/services.html#server-wms-getprojectsettings" target="_blank" rel="noopener noreferrer">https://docs.qgis.org/3.16/en/docs/server_manual/services.html#server-wms-getprojectsettings</a></p>
<p>The information of the GetProjectSettings response can be parsed by the client and used to generate an appropriate GetMap request with the correct layer order.</p>
<p>Hope this helps,</p>
<p>Andreas</p>
<p id="v1gmail-m_791307730268617019gmail-m_-6185293330888090245reply-intro">On 2021-03-31 18:07, 1520 gis wrote:</p>
<blockquote style="padding: 0px 0.4em; border-left: 2px solid #1010ff; margin: 0px;">
<div id="v1gmail-m_791307730268617019gmail-m_-6185293330888090245replybody1">
<div>
<div dir="ltr">Hi developers,
<div> </div>
<div>I have tried to change the QGIS-Server layer order using QGIS Desktop  Layers Panel and L.TileLayer.WMS (Leaflet) zIndex options. None of them could change the layer order. It seems that QGIS-Server always serves from bottom to Top: raster images, polygons, lines and points by default. Is there any way to change these settings?</div>
<div> </div>
<div>Kind regards</div>
<div> </div>
<div>Julierme</div>
<div> </div>
<div> </div>
</div>
</div>
</div>
<br />
<div style="margin: 0px; padding: 0px; font-family: monospace;">_______________________________________________<br />Qgis-user mailing list<br /><a href="mailto:Qgis-user@lists.osgeo.org" rel="noreferrer">Qgis-user@lists.osgeo.org</a><br />List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank" rel="noopener noreferrer">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><br />Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank" rel="noopener noreferrer">https://lists.osgeo.org/mailman/listinfo/qgis-user</a></div>
</blockquote>
<p><br /></p>
</div>
</blockquote>
</div>
</blockquote>
</div>
</div>
</div>
</blockquote>
<p><br /></p>

</body></html>