Initial commit
This commit is contained in:
39
#pma/templates/table/search/geom_func.phtml
Normal file
39
#pma/templates/table/search/geom_func.phtml
Normal file
@ -0,0 +1,39 @@
|
||||
<!-- Displays 'Function' column if it is present -->
|
||||
<td>
|
||||
<?php
|
||||
$geom_types = PMA\libraries\Util::getGISDatatypes();
|
||||
?>
|
||||
|
||||
<?php
|
||||
/**
|
||||
* if a geometry column is present
|
||||
*/
|
||||
if (in_array($columnTypes[$column_index], $geom_types)): ?>
|
||||
<select class="geom_func"
|
||||
name="geom_func[<?= $column_index; ?>]">
|
||||
|
||||
<?php
|
||||
// get the relevant list of GIS functions
|
||||
$funcs = PMA\libraries\Util::getGISFunctions(
|
||||
$columnTypes[$column_index], true, true
|
||||
);
|
||||
?>
|
||||
|
||||
<?php
|
||||
/**
|
||||
* For each function in the list of functions,
|
||||
* add an option to select list
|
||||
*/
|
||||
foreach ($funcs as $func_name => $func): ?>
|
||||
<?php $name = htmlspecialchars(
|
||||
isset($func['display']) ? $func['display'] : $func_name
|
||||
); ?>
|
||||
<option value="<?= $name; ?>">
|
||||
<?= $name; ?>
|
||||
</option>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
<?php else: ?>
|
||||
|
||||
<?php endif; ?>
|
||||
</td>
|
Reference in New Issue
Block a user