<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<font size="2" face="Arial">Hi Seth,<br>
<br>
I also do not know the PHP C-API so cannot go that route. I had
considered using the moveLayer functions to solve my problem and
will have to go that route.<br>
<br>
</font>
<div class="moz-signature"><b>Worth Lutz</b><br>
<br>
<br>
</div>
<br>
<br>
<div class="moz-cite-prefix">On 9/24/24 07:44, Seth G wrote:<br>
</div>
<blockquote type="cite"
cite="mid:63fad507-096a-43dc-af38-022fc9ac1f62@app.fastmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title></title>
<style type="text/css">p.MsoNormal,p.MsoNoSpacing{margin:0}</style>
<div>Hi,<br>
</div>
<div><br>
</div>
<div>You are correct re the note - this has only been implemented
in Python MapScript - see <a
href="https://github.com/MapServer/MapServer/blob/893d9a48e1956a1e039ce5e44eed5466dd5e7907/src/mapscript/python/pyextend.i#L268"
moz-do-not-send="true" class="moz-txt-link-freetext">https://github.com/MapServer/MapServer/blob/893d9a48e1956a1e039ce5e44eed5466dd5e7907/src/mapscript/python/pyextend.i#L268</a>.<br>
</div>
<div>You could try and add an equivalent to the PHP MapScript but
you'd need to know the PHP C-API (which I do not!). It would be
added to <a
href="https://github.com/MapServer/MapServer/blob/main/src/mapscript/phpng/php7module.i"
moz-do-not-send="true" class="moz-txt-link-freetext">https://github.com/MapServer/MapServer/blob/main/src/mapscript/phpng/php7module.i</a><br>
</div>
<div><br>
</div>
<div>Alternatively, you could write your own helper function in
PHP using the moveLayerDown and moveLayerUp methods in mapObj
and the mapscript.layerObj index property to get your desired
layer order - <a
href="https://mapserver.org/mapscript/mapscript-api/stub/mapscript.mapObj.html#mapscript.mapObj"
moz-do-not-send="true" class="moz-txt-link-freetext">https://mapserver.org/mapscript/mapscript-api/stub/mapscript.mapObj.html#mapscript.mapObj</a><br>
</div>
<div><br>
</div>
<div>Seth<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div id="sig62266145">
<div class="signature">--<br>
</div>
<div class="signature">web:<a href="https://geographika.net"
moz-do-not-send="true" class="moz-txt-link-freetext">https://geographika.net</a>
& <a href="https://mapserverstudio.net"
moz-do-not-send="true" class="moz-txt-link-freetext">https://mapserverstudio.net</a><br>
</div>
<div class="signature">mastodon: @<a
href="mailto:geographika@mastodon.social"
moz-do-not-send="true" class="moz-txt-link-freetext">geographika@mastodon.social</a><br>
</div>
</div>
<div><br>
</div>
<div>On Tue, Sep 24, 2024, at 1:20 PM, Worth Lutz via
MapServer-dev wrote:<br>
</div>
<blockquote type="cite" id="qt" style="">
<div><span class="font" style="font-family:Arial;"><span
class="size" style="font-size:13px;">Hi All,<br>
<br>
I'm trying to do an upgrade to MapServer v8 and
Mapscript-ng. I'm unable to get
$map->setLayersDrawingOrder($layerOrderArrayOfIntegers)
to work. I get this error:<br>
<br>
Expected SWIGTYPE_p_int for argument 2 of
mapObj_setLayersDrawingOrder<br>
<br>
I'm assuming it is because of this note in the
documentation:<br>
<br>
Note Unless the proper typemap is implemented for the
module’s language users will not be able to pass arrays or
lists to this method and it will be unusable.<br>
<br>
I spent yesterday looking at SWIG and typemaps but as I do
not use C I did not understand what I was reading.<br>
<br>
Is there anything I can do to use setLayersDrawingOrder in
my code?<br>
<br>
Thanks,</span></span></div>
<div class="qt-moz-signature">
<div>-- <br>
</div>
<div> <b>Worth Lutz</b><br>
</div>
<div><br>
</div>
</div>
<div>_______________________________________________<br>
</div>
<div>MapServer-dev mailing list<br>
</div>
<div><a href="mailto:MapServer-dev@lists.osgeo.org"
moz-do-not-send="true" class="moz-txt-link-freetext">MapServer-dev@lists.osgeo.org</a><br>
</div>
<div><a
href="https://lists.osgeo.org/mailman/listinfo/mapserver-dev"
moz-do-not-send="true" class="moz-txt-link-freetext">https://lists.osgeo.org/mailman/listinfo/mapserver-dev</a><br>
</div>
<div><br>
</div>
</blockquote>
<div><br>
</div>
</blockquote>
<br>
</body>
</html>