This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@media screen and (min-width: 1000px){ | |
.container { | |
width: 1000px; | |
margin-left: auto; | |
margin-right: auto; | |
height: 800px; | |
} | |
.map { | |
height: 700px; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@media screen and (min-width: 800px){ | |
.container2 { | |
width :40%; | |
} | |
.map { | |
width : 60%; | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function ZoomTo(xVal, yVal) { | |
// Remove the class open from divResults, | |
// so that it will slide back out of view | |
var drawer = document.getElementById("divResults"); | |
drawer.classList.toggle('open'); | |
/// | |
OneMap.showLocation(xVal, yVal); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function displayData(resultData) { | |
var results = resultData.results; | |
if (results == 'No results') { | |
document.geElementById('divResults').innerHTML = "No result(s) found"; | |
return false | |
} | |
else { | |
// Set the divResults class as open to slide in from off screen | |
var drawer = document.getElementById("divResults"); | |
drawer.classList.toggle('open'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* set padding and height to 100% */ | |
html, body, #mapDiv { | |
padding: 0; | |
margin: 0; | |
height: 100%; | |
font-family: sans-serif; | |
} | |
/* use flex and flex-wrap */ | |
.container { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="container"> | |
<div class="box heading"> | |
<h2>Address Search API Usage (WGS84 Coordinate System)</h2> | |
</div> | |
<div class="box container2"> | |
<div class="box searchbox"> | |
<input type="text" id="txtSearchText" value='City Hall' /> | |
<input type="button" onclick="GetSearchData();" value="Search" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<table style="width: 436px"> | |
<tr> | |
<th colspan="2"> | |
Address Search API Usage (WGS84 Coordinate System) | |
</th> | |
</tr> | |
<tr> | |
<td> | |
Search Text : | |
</td> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var resultTableViewController = UITableViewController() | |
var searchController = UISearchController() |