Qgis ใส่สี sld และนำเข้า geoserver

Preview:

Citation preview

แคปเจอร์ QGIS ใส่สี SLD และนําเข้า Geoserver

เปิด GeoServer

Openlayer boundary

Openlayer building

เปิดโปรแกรม QGIS

Add PostGIS Layer

New

เซตคา่ตามภาพ แล้วกด Ok

ok

ทําการ Connect

เลือกไฟล์ boundary,building>>Add

ทําการเซตคา่ WGS84

ได้ภาพท่ีต้องการ

เปล่ียนสี>>Style>>Save Style>>SLD File

บนัทกึข้อมลูตามภาพ

เปิดชัน้ข้อมลู building

คลกิขวา>>Open Attribute Table

ได้ข้อมลูดงัภาพ

คลกิขวาท่ี building อีกครัง้ ให้เลือก Categorized

Style>>Save Style>>SLD File

ทําการบนัทกึดงัภาพ

เปิด Geoserver>>Styles

เลือกไฟล์ท่ีจะใช้งาน

Wait to Upload.

เม่ือโหลดเสร็จให้คลกิ submit

ไปท่ี Layer

เลือก boundary

เลือก Publishing

เปล่ียน Default Style เป็นข้อมลูท่ีเราไปสร้างขึน้

ไปท่ี Layer Preview

เลือกท่ี openLayers ดบัเบิล้คลิ๊ก ก็จะได้รูปแบบนีข้ึน้มา

เลือก building

คลกิท่ี Publishing

เปล่ียน Default Style เป็นข้อมลูท่ีเราไปสร้างขึน้

Style>>Save Style>>SLD File แล้วบนัทกึ

Recommended