Paste This Code in Your Text-Editor and Save With - Extension
Paste This Code in Your Text-Editor and Save With - Extension
Paste This Code in Your Text-Editor and Save With - Extension
com/
<!DOCTYPE html>
<html>
<head>
<title>Place Autocomplete</title>
<meta charset="utf-8">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<style>
/* Always set the map height explicitly to define the size of the div
#map {
height: 100%;
html, body {
height: 100%;
margin: 0;
https://sumsols.com/
padding: 0;
.controls {
margin-top: 10px;
box-sizing: border-box;
-moz-box-sizing: border-box;
height: 32px;
outline: none;
#pac-input {
background-color: #fff;
font-family: Roboto;
font-size: 15px;
font-weight: 300;
margin-left: 12px;
text-overflow: ellipsis;
width: 300px;
#pac-input:focus {
https://sumsols.com/
border-color: #4d90fe;
.pac-container {
font-family: Roboto;
#type-selector {
color: #fff;
background-color: #4d90fe;
#type-selector label {
font-family: Roboto;
font-size: 13px;
font-weight: 300;
</style>
</head>
<body>
<?php
include('connection.php');
if(isset($_POST['submit']))
{
https://sumsols.com/
$name=$_POST['name'];
$lat=$_POST['lat'];
$lng=$_POST['lng'];
$location=$_POST['location'];
VALUES ('$name','$lat','$lng','$location')";
if(mysqli_query($con,$query)){
?>
<div class="container">
<div class="row">
Name
placeholder="Enter a location">
https://sumsols.com/
<div id="type-selector" class="controls">
<label for="changetype-all">All</label>
</div>
</div>
</div><!--End of row-->
</form>
</div><!--End of container-->
<script>
// <script src="https://maps.googleapis.com/maps/api/js?key=YOUR_API_KEY&libraries=places">
function initMap() {
zoom: 13
});
document.getElementById('pac-input'));
https://sumsols.com/
map.controls[google.maps.ControlPosition.TOP_LEFT].push(input);
map.controls[google.maps.ControlPosition.TOP_LEFT].push(types);
autocomplete.bindTo('bounds', map);
map: map,
});
autocomplete.addListener('place_changed', function() {
infowindow.close();
marker.setVisible(false);
if (!place.geometry) {
// User entered the name of a Place that was not suggested and
return;
}
https://sumsols.com/
// If the place has a geometry, then present it on a map.
if (place.geometry.viewport) {
map.fitBounds(place.geometry.viewport);
} else {
map.setCenter(place.geometry.location);
url: place.icon,
}));
marker.setPosition(place.geometry.location);
marker.setVisible(true);
//alert("Lat= "+item_Lat+"_____Lang="+item_Lng+"_____Location="+item_Location);
$("#lat").val(item_Lat);
$("#lng").val(item_Lng);
$("#location").val(item_Location);
https://sumsols.com/
if (place.address_components) {
address = [
].join(' ');
infowindow.open(map, marker);
});
// Autocomplete.
radioButton.addEventListener('click', function() {
autocomplete.setTypes(types);
});
setupClickListener('changetype-all', []);
setupClickListener('changetype-address', ['address']);
https://sumsols.com/
setupClickListener('changetype-establishment', ['establishment']);
setupClickListener('changetype-geocode', ['geocode']);
</script>
<script src="https://maps.googleapis.com/maps/api/js?key=AIzaSyCR5PFyvraK8Cqbu-vQu7UAR-
NkcABHNuw&libraries=places&callback=initMap"
async defer></script>
</body>
</html>