Webdav with curl vs Javascript
问题 I try to access a Nextcloud server using Webdav. Using curl this works: curl -X PROPFIND -u user:pwd https://nextcloudserver.com/remote.php/dav/files/user Using Javascript this I get a 503 error const url = "https://nextcloudserver.com/remote.php/dav/files/user/" var xhr = new XMLHttpRequest(); xhr.open('PROPFIND', url, true); xhr.setRequestHeader("Authorization", "Basic " + btoa("username:pwd")); xhr.withCredentials=true; xhr.send(); Any idea? 回答1: this is working for me: const url = "https: