芜湖不芜
您可以通过以下方式将 html 代码放入弹出窗口中IFrame:import foliumm = folium.Map(location=[43.775, 11.254], zoom_start=5)html = '''1st line<br>2nd line<br>3rd line'''iframe = folium.IFrame(html, width=100, height=100)popup = folium.Popup(iframe, max_width=100)marker = folium.Marker([43.775, 11.254], popup=popup).add_to(m)m你得到: