Table of Contents
Cách enable outputFormat=text/javascript trong Geoserver Khi chưa bật lên, nếu truy vấn Service WFS chúng ta sẽ có lỗi sau:
http://localhost:8080/geoserver/ungdunggis/ows?SERVICE=WFS&VERSION=1.1.1&REQUEST=GetFeature&typename=ungdunggis:hcm&srsname=EPSG:4326&outputFormat=text/javascriptĐể fixed lỗi này, chúng ta sẽ edit file web.xml
C:\Program Files (x86)\GeoServer 2.10.2\webapps\geoserver\WEB-INF\web.xmlTìm đến dòng text/javascript như sau: Và bỏ hết ghi chú để config trên có hiệu lực Sau đó thì restart lại geoserver Kết quả trả về ta sẽ có như sau: Have fun! -soiqualang_chentreu ]]>