disableLog(); // Vérification de l'activation de l'option localisation $f->handle_if_no_localisation(); // if (isset ($_GET['idx'])){ $idx=$f->db->escapeSimple($_GET['idx']); }else{ $idx=0; } if (isset ($_GET['lst'])){ $lst=$f->db->escapeSimple($_GET['lst']); $lst = str_replace("''","'",$lst); }else{ $lst=''; } $panier=""; if ($lst!='') { $sql = "select pa_sql from ".DB_PREFIXE."om_sig_map_wms where om_sig_map_wms='".$idx."'"; $res = $f -> db -> query($sql); $pa_sql = ""; if (DB :: isError($res)){ die($res->getMessage()."erreur".$sql); }else{ while ($row=& $res->fetchRow(DB_FETCHMODE_ASSOC)){ if($row["pa_sql"]!='') $pa_sql = $row["pa_sql"]; } } if ($pa_sql!='') { $pa_sql=str_replace("&lst",$lst,$pa_sql); $pa_sql=str_replace("&DB_PREFIXE",DB_PREFIXE,$pa_sql); $res = $f -> db -> query($pa_sql); if (DB :: isError($res)){ die($res->getMessage()."erreur ".$sql); }else{ $panier = 'GEOMETRYCOLLECTION('; while ($row=& $res->fetchRow(DB_FETCHMODE_ASSOC)){ if($row["geom"]!='') $panier.= $row["geom"].","; } } $panier=substr($panier,0, strlen($panier)-1); $panier.= ")"; } } echo $panier; ?>