How do I create a simple, custom WebDav application?
To provide some context, I'm interested in the creation 开发者_如何学Cof an app which allows editing of HTML interfaces, simplifying things down a bit though I want to investigate WebDav as an option for controlling the collaborative data aspect of this app. I want several collab features to be a part of what I'm building.
I'm running WAMPP 2 (PHP 5.3, Apache 2.2.11) on WinXPSP3. My live site has a similar setup, though it is important to note that I cannot change whatever config there is on my live site (http://www.codefinger.co.nz).
My first attempt, after reading doc after doc after doc explaining what WebDav is, was to simply get an example up and running: http://johnnydebris.net/javascript/.files/davclient.js-0.1.tar.gz (explanation and docs included in package). Unfortunately I couldn't get it running locally, or on my live site. There's a great chance I just don't have either configured appropriately - but I'm no server hotshot, I wouldn't know.
It looked promising after I commented in 3 davishly named mods in httpd.conf; dav_module, dav_fs_module and dav_lock_module. Restarted Apache, all 3 have a tick in the loaded modules listing available through WAMPP manager, but no functional cigar.
Are there some basic tests I can do to see if I'm configured right?
Am I missing the point of WebDavs needs? Do I require C scripts or Python, or Rails or something else?
Must I be running a Linux box? (I ask because many of the trawlings I found through Google were Linux related, I'm a Windows duct-tape programmer, sorry :/)
Ok, any clarification, or counter-questions, or better solutions and advice welcome - I'm not in a hurry save for the fact that I've been trying to get WebDav up and running on and off for a month now by myself.
If is not enough to comment out the LoadModule directive. You must then enable WebDAV for a directory that's writable by the web server. See the documentation.
This example from the manual requires basic authentication (you should do it with digest or basic over https) for all non-read operations:
DavLockDB /usr/local/apache2/var/DavLock
<Location /foo>
Order Allow,Deny
Allow from all
Dav On
AuthType Basic
AuthName DAV
AuthUserFile user.passwd
<LimitExcept GET OPTIONS>
Require user admin
</LimitExcept>
</Location>
精彩评论