Skip to content

Commit

Permalink
HTTPS will not see OpenStreetMaps due to CSP. So do not show the chec…
Browse files Browse the repository at this point in the history
…kbox also
  • Loading branch information
madhuracj committed Apr 14, 2013
1 parent 818167a commit 2ce7be7
Showing 1 changed file with 16 additions and 7 deletions.
23 changes: 16 additions & 7 deletions tbl_gis_visualization.php
Original file line number Diff line number Diff line change
Expand Up @@ -149,17 +149,22 @@
<tr><td></td>
<td class="button"><input type="submit" name="displayVisualizationBtn" value="<?php echo __('Redraw'); ?>" /></td>
</tr>
<?php
if (! $GLOBALS['PMA_Config']->isHttps()) {
?>
<tr><td class="choice" colspan="2">
<input type="checkbox" name="visualizationSettings[choice]" id="choice" value="useBaseLayer"
<?php

if (isset($visualizationSettings['choice'])) {
echo(' checked="checked"');
}
?>
<?php
if (isset($visualizationSettings['choice'])) {
echo(' checked="checked"');
}
?>
/>
<label for="choice"><?php echo __("Use OpenStreetMaps as Base Layer"); ?></label>
</td></tr>
<?php
}
?>
</table>
<input type="hidden" name="displayVisualization" value="redraw">
<input type="hidden" name="sql_query" value="<?php echo htmlspecialchars($sql_query); ?>" />
Expand Down Expand Up @@ -204,7 +209,11 @@
<script language="javascript" type="text/javascript">
function drawOpenLayers()
{
<?php echo (PMA_GIS_visualizationResults($data, $visualizationSettings, 'ol')); ?>
<?php
if (! $GLOBALS['PMA_Config']->isHttps()) {
echo (PMA_GIS_visualizationResults($data, $visualizationSettings, 'ol'));
}
?>
}
</script>
</fieldset>
Expand Down

0 comments on commit 2ce7be7

Please sign in to comment.