If all the rows contain SRID, use OpenStreetMaps on the initial loading

This commit is contained in:
Madhura Jayaratne 2011-06-17 06:58:21 +05:30
parent 3792b786d8
commit 1b2ed15272

View File

@ -70,6 +70,17 @@ while ($row = PMA_DBI_fetch_assoc($modified_result)) {
$data[] = $row;
}
// If all the rows contain SRID, use OpenStreetMaps on the initial loading.
if (! isset($_REQUEST['displayVisualization'])) {
$visualizationSettings['choice'] = 'useBaseLayer';
foreach ($data as $row) {
if ($row['srid'] == 0) {
unset($visualizationSettings['choice']);
break;
}
}
}
if (isset($_REQUEST['saveToFile'])) {
$file_name = $_REQUEST['fileName'];
if ($file_name == '') {