X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FWeb%2FDispatch%2FHTTPMethods.pm;fp=lib%2FWeb%2FDispatch%2FHTTPMethods.pm;h=c78c65061cf09e1a48a363b4ac80f2bf27ee0f06;hb=b54172e8e85b09c0de0b167f1b682af54f4d8379;hp=1f40c82d3ee481221c49fcbab3fed14201fcb3be;hpb=4c7f2f3e48c65a9ff4d8d473dab752b365df9c6d;p=catagits%2FWeb-Simple.git diff --git a/lib/Web/Dispatch/HTTPMethods.pm b/lib/Web/Dispatch/HTTPMethods.pm index 1f40c82..c78c650 100644 --- a/lib/Web/Dispatch/HTTPMethods.pm +++ b/lib/Web/Dispatch/HTTPMethods.pm @@ -112,15 +112,16 @@ Web::Dispatch::HTTPMethods - Helpers to make RESTFul Dispatchers Easier =head1 DESCRIPTION Exports the most commonly used HTTP methods as subroutine helpers into your -L based application. Additionally adds an automatic HTTP code 405 -C if none of the HTTP methods match for a given dispatch and +L based application. +Use of these methods additionally adds an automatic HTTP code 405 +C response if none of the HTTP methods match for a given dispatch and also adds a dispatch rule for C if no C exists but a C does (in which case the C returns the C dispatch with an empty body.) -We also add at the end of the chain support for the OPTIONS method (if you do -not add one yourself. This defaults to http 200 ok + Allows http headers. +We also add support at the end of the chain for the OPTIONS method. +This defaults to HTTP 200 OK + Allows http headers. -Also we try to set correct HTTP headers such as C as makes sense based +We also try to set correct HTTP headers such as C as makes sense based on your dispatch chain. The following dispatch chains are basically the same: