runFormPostNoNonce

This commit is contained in:
Michael Snoyman 2010-10-25 12:04:39 +02:00
parent 0fc2cccfef
commit 51943f9a11

View File

@ -25,6 +25,7 @@ module Yesod.Form
, runFormGet
, runFormMonadGet
, runFormPost
, runFormPostNoNonce
, runFormMonadPost
, runFormGet'
, runFormPost'
@ -93,6 +94,13 @@ fieldsToDivs = mapFormXml $ mapM_ go
|]
clazz fi = if fiRequired fi then "required" else "optional"
-- | Run a form against POST parameters, without CSRF protection.
runFormPostNoNonce :: GForm s m xml a -> GHandler s m (FormResult a, xml, Enctype)
runFormPostNoNonce f = do
rr <- getRequest
(pp, files) <- liftIO $ reqRequestBody rr
runFormGeneric pp files f
-- | Run a form against POST parameters.
--
-- This function includes CSRF protection by checking a nonce value. You must