Hoogle Search
Within LTS Haskell 24.39 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
generateFormGet :: MonadHandler m => (Markup -> MForm m a) -> m (a, Enctype)yesod-form Yesod.Form.Functions Deprecated: Will require RenderMessage in next version of Yesod
generateFormGet' :: MonadHandler m => (Markup -> MForm m (FormResult a, xml)) -> m (xml, Enctype)yesod-form Yesod.Form.Functions Since 1.3.11
-
yesod-form Yesod.Form.Functions Similar to runFormPost, except it always ignores the currently available environment. This is necessary in cases like a wizard UI, where a single page will both receive and incoming form and produce a new, blank form. For general usage, you can stick with runFormPost.
-
yesod-form Yesod.Form.Functions Creates a hidden field on the form that identifies it. This identification is then used to distinguish between missing and wrong form data when a single handler contains more than one form. For instance, if you have the following code on your handler:
((fooRes, fooWidget), fooEnctype) <- runFormPost fooForm ((barRes, barWidget), barEnctype) <- runFormPost barForm
Then replace it with((fooRes, fooWidget), fooEnctype) <- runFormPost $ identifyForm "foo" fooForm ((barRes, barWidget), barEnctype) <- runFormPost $ identifyForm "bar" barForm
Note that it's your responsibility to ensure that the identification strings are unique (using the same one twice on a single handler will not generate any errors). This allows you to create a variable number of forms and still have them work even if their number or order change between the HTML generation and the form submission. -
yesod-form Yesod.Form.Functions Converts a monadic form MForm into another monadic form WForm.
newFormIdent :: forall (m :: Type -> Type) . Monad m => MForm m Textyesod-form Yesod.Form.Functions Get a unique identifier.
runFormGet :: MonadHandler m => (Markup -> MForm m a) -> m (a, Enctype)yesod-form Yesod.Form.Functions No documentation available.
-
yesod-form Yesod.Form.Functions This function is used to both initially render a form and to later extract results from it. Note that, due to CSRF protection and a few other issues, forms submitted via GET and POST are slightly different. As such, be sure to call the relevant function based on how the form will be submitted, not the current request method. For example, a common case is displaying a form on a GET request and having the form submit to a POST page. In such a case, both the GET and POST handlers should use runFormPost.
runFormPostNoToken :: MonadHandler m => (Markup -> MForm m a) -> m (a, Enctype)yesod-form Yesod.Form.Functions No documentation available.
wFormToAForm :: forall (m :: Type -> Type) a . MonadHandler m => WForm m (FormResult a) -> AForm m ayesod-form Yesod.Form.Functions Converts a monadic form WForm into an applicative form AForm.