I'm using Mapserver 7.4.0-dev and MapScript PHP.
In previous versions of MapServer and MapScript (https://mapserver.org/mapscript/php/index-5.6.html#shapeobj), I could query a shapeObj after its values. And get a key => value array with all the data fields.
Example:
public function __construct(\shapeObj $shape)
{
foreach ($shape->values as $key => $value) {
//Do something;
}
}
In the new Mapserver and MapScript (https://mapserver.org/mapscript/mapscript.html#shapeobj), there is no $shape->values attribute.
I can get the value of element X but no the key name (Example "Gis_ID") by using this function:
$shape->getValue(3);
But this does not help my much. My map sources are dynamic and i need to target the data by IDs, and not a random array index.
Can anyone help me figure this out? :)