I have an issue with displaying information in folium popup where the information is retrieved from a JSON file. Currently, my codes are retrieving only the last piece of information from my JSON file and inserting it into all popup, thus all my popup are showing only that one piece of information. I can't seem to work it out where each node has its own unique information in their popup. Any help is appreciated.
# reading JSON file
with open('exportBuilding.geojson') as access_json:
read_content = json.load(access_json)
feature_access = read_content['features']
# Creating Folium Map
m = folium.Map(location=[1.400150, 103.910172], titles="Punggol", zoom_start=17)
nodeData = os.path.join('exportBuilding.geojson')
geo_json = folium.GeoJson(nodeData)
# retrieve all names and store in popup
for feature_data in feature_access:
property_data = feature_data['properties']
geo_json.add_child(folium.Popup(property_data['name'))
geo_json.add_to(m)