Open dakhnod opened 5 years ago
To report back a 501 you can throw a https://github.com/sabre-io/dav/blob/master/lib/DAV/Exception/NotImplemented.php
By default there is no message in exceptions/error responses defined within webdav ...
Still you can implement our own exception class with custom rendering of the response body like this https://github.com/sabre-io/dav/blob/09ed9f1dc417ccdca0f31dffdf9be565285cc2f0/lib/DAV/Exception/Locked.php#L58
Let me know if this is what you are searching for ....
Thanks for the response, i have managed to report a 501 one way or another.
What matters to me is the question whether there is a way to get WebDAV-compliant clients to display an arbitary string as a message.
The client i have worked with just showed an "error"-popup, not even displaying something like "not implemented". So, i wanted to find out if there is some way in the protocoll to get clients to show an arbitary string to the user.
So, i wanted to find out if there is some way in the protocoll to get clients to show an arbitary string to the user.
No. There is nothing related defined in the specifications: https://tools.ietf.org/html/rfc4918
Sometimes, i need to return a 501 status code in order to indicate, that a certain operation is not implemented. Is there any conventional way to return a message, which a WebDAV client should show besides simply "error"? Something that explains which feature exactly is blocked and thus causes a 501?