Ejemplo n.º 1
0
$stArrCollJson = array_key_exists("jsoncollstarr", $_REQUEST) ? $_REQUEST["jsoncollstarr"] : '';
$stArrSearchJson = array_key_exists("starr", $_REQUEST) ? $_REQUEST["starr"] : '';
$sharedMapManager = new MappingShared();
$sharedMapManager->setFieldArr(0);
$mapWhere = '';
$genObs = $sharedMapManager->getGenObsInfo();
if ($mapType == 'taxa') {
    $taxaMapManager = new TaxonProfileMap();
    $taxaMapManager->setTaxon($taxonValue);
    $synMap = $taxaMapManager->getSynMap();
    $taxaMapManager->getTaxaMap();
    $mapWhere = $taxaMapManager->getTaxaSqlWhere();
    $tArr = $taxaMapManager->getTaxaArr();
    $sharedMapManager->setTaxaArr($tArr);
} elseif ($mapType == 'occquery') {
    $occurMapManager = new OccurrenceMapManager();
    if ($stArrCollJson && $stArrSearchJson) {
        $collStArr = json_decode($stArrCollJson, true);
        $searchStArr = json_decode($stArrSearchJson, true);
        $stArr = array_merge($searchStArr, $collStArr);
        $occurMapManager->setSearchTermsArr($stArr);
    }
    $mapWhere = $occurMapManager->getOccurSqlWhere();
    $tArr = $occurMapManager->getTaxaArr();
    $stArr = $occurMapManager->getSearchTermsArr();
    $sharedMapManager->setSearchTermsArr($stArr);
}
$sharedMapManager->setTaxaArr($tArr);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
Ejemplo n.º 2
0
<?php

include_once '../config/symbini.php';
include_once $serverRoot . '/classes/OccurrenceMapManager.php';
header("Content-Type: text/html; charset=" . $charset);
$mapManager = new OccurrenceMapManager();
$mapManager->setMapType('occquery');
$kmlFilePath = $mapManager->writeKMLFile();
?>