如何解决tomTomMap.addSource() 中的“归因”键是什么?
我一直在寻找如何将 openweathermap 图层放到 tom-tom 地图上,我找到了一个解决方案:
if (!-e $request_filename) {
rewrite ^.*$ /index.php last;
}
location / {
try_files $uri $uri/ /index.php?q=$uri$args;
}
location ~* \.php$ {
if ($uri !~ "^/uploads/") {
fastcgi_pass unix:/var/run/php/php7.4-fpm.sock;
}
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param SCRIPT_NAME $fastcgi_script_name;
}
我不知道这个“归因”是什么,因此我不断得到
你能帮我找出它是什么吗?
tomTomMap.addSource('owm_source',{
type: 'raster',tiles: [
'https://tile.openweathermap.org/map/clouds_new/{1}/{51}/{20}.png?{app_id}'
],tileSize: 256,minZoom: 0,maxZoom: 12,attribution: openWeatherMapAttribution
});
解决方法
署名只是一个简单的 HTML 片段,带有指向供应商的链接。 tomtom 对此的记录非常糟糕。
所以 openWeatherMapAttribution
变量可以只是字符串:'<a href="//example.org">Copyright</a>'
。
您可以查看他们的文档 here,但是,正如前面提到的,它的文档非常糟糕。
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。