Skip to content

Instantly share code, notes, and snippets.

@elpete
Created May 26, 2016 17:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save elpete/1fc1973e6b93bcd5dfc6e6c6c835395c to your computer and use it in GitHub Desktop.
Save elpete/1fc1973e6b93bcd5dfc6e6c6c835395c to your computer and use it in GitHub Desktop.
Simple Request Context Decorator to spoof the HTTP method with hidden _method fields.
component extends='coldbox.system.web.context.RequestContextDecorator' {
string function getHTTPMethod() {
return getRequestContext().getValue('_method', cgi.REQUEST_METHOD);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment