I am building a RESTFUL API and need to get Apache to accept PUT requests. Whenever I put to a URL, I am getting a 403 Forbidden
error.
curl -X PUT api.example.com/api/foo
I have tried to add the following to my Virtual Directory (To no avail):
<Limit GET POST PUT DELETE HEAD OPTIONS>
Order allow,deny
Allow from all
</Limit>
<LimitExcept GET POST PUT DELETE HEAD OPTIONS>
Order deny,allow
Deny from all
</LimitExcept>
What other config settings might be causing this?
EDIT
I am re-writing my URL's, all get re-written to index.php as follows:
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !\.
RewriteRule ^(.*)$ /api/index.php/$1 [L,QSA]