I have a map in QGIS displaying many languages being spoken in the displayed area. Each one of them has a designated marker with a HTML frame that shows up on hover.
However, in this frame I would like to display data like the ISO-code of that language. This data is stored in a text file that I added to the project via layers.
It contains the X Y coordinates, the language name (displayed on the map) and the ISO-code, each tab separated.
The HTML frame code is this (http://pastebin.com/xZYCk6S0 if it's not working properly):
<!DOCTYPE html>
<html>
<head>
<style>
#map {
height: 400px;
width: 100%;
}
</style>
</head>
<body>
<div style="width:550;height:550; background-color: lightgrey">
<p><font color="black">Search this ISO code on</font></p>
<p><font color="blue"><a href="http://wals.info/languoid">WALS</a></font></p>
</div>
<h3>This language is found here:</h3>
<div id="map"></div>
<script>
function initMap() {
var uluru = {lat: 50.115017, lng: 8.634350};
var map = new google.maps.Map(document.getElementById('map'), {
zoom: 4,
center: uluru
});
var marker = new google.maps.Marker({
position: uluru,
map: map
});
}
</script>
<script async defer
src="https://maps.googleapis.com/maps/api/js?key=MYAPIKEY&callback=initMap">
</script>
</body>
</html>
I haven't found out yet how to reference the data on the map so that the frame would say: "language_name" with ISO-Code "ISO_code" is found here: So that each frame adaptively has the right information in it.