In my geoserver I have a layer with a default style (SLD) and i want to add another style to this layer with Curl.
I tried command below with <style></style>
instead of <defaultStyle></defaultStyle>
but without success :
curl -u admin:pass -XPUT -H 'Content-type: text/xml' -d '<layer><style><name>sld_name</name><workspace>workspace_name</workspace></style></layer>' http://localhost:8080/geoserver/rest/layers/workspace_name:layer_name
Unfortunately I don't have found help in geoserver cookbook : http://docs.geoserver.org/latest/en/user/rest/examples/curl.html.
Anybody know the answer ?