Questions tagged [yesod]

Yesod is a Haskell web framework for productive development of type-safe, RESTful, high performance web applications.

Yesod is a Haskell web framework for productive development of type-safe, RESTful, high performance web applications.

Yesod leverages Haskell's type system to turn runtime bugs into compule-time errors, for example to avoid XSS attacks or character encoding issues. Yesod contains several DSLs for templating ( for HTML, for Javascript, and or for CSS), to store data (Persistent), for routing, etc.

1334 questions
0
votes
1 answer

Can Warp in yesod used to host CGI application?

An old python CGI application is now running under ocsigen with cgimod extension. Whether or not warp support CGI application just by some configuration ? Any suggestion is appreciated!
z_axis
  • 8,272
  • 7
  • 41
  • 61
0
votes
1 answer

Using Parsec with Yesod: cabal dependencies error

I want to use Parsec in a Yesod project but get a cabal error. Here is what i added to my code: import Text.ParserCombinators.Parsec Got this error: Could not find module `Text.ParserCombinators.Parsec' So i added 'parsec' to my .cabal file and…
somesoaccount
  • 1,267
  • 15
  • 37
0
votes
1 answer

Streaming file archive created on the fly in web server

I have a Yesod application (but question is more general than this) that allows file uploads. I also allow file dowloads. I would like to allow users download multiple files with single link. As per this question: How to download multiple files with…
Tener
  • 5,280
  • 4
  • 25
  • 44
0
votes
1 answer

How to redirect within a monad in Yesod?

I'm currently using the fb package to write a Yesod app that takes data from Facebook. In my Handler, I've managed to get the first step of the authentication to work, but I need to redirect to the url that getUserAccessTokenStep1 returns, which…
Squazic
  • 3,670
  • 3
  • 26
  • 40
0
votes
1 answer

Cabal Configure fails on Configuring test (Windows)

I am new to Haskell and trying to install Yesod on a windows machine using cabal. When I try to do a yesod devel I get a build failure, saing I must run configure first. Then when I run a cabal configure it fails with the following…
BobuSumisu
  • 118
  • 1
  • 5
-1
votes
1 answer

Is there a way to pull multiple Hamlet and Cassius files into a webpage using scaffolds?

I'm trying to use Atomic Design with Yesod Scaffolds. From what I can tell, I should be able to do it by making widgets, or using interpolation. However; I can't really seem to find much documentation regarding this, and the book on yesodweb isn't…
Enus
  • 1
-1
votes
1 answer

Assigning Asc/ Desc to variable later causes a compiler error

I am getting a compiler error when I try to have something like: getOrder :: Text -> SelectOpt Event getOrder text = case text of "id" -> direction EventId "title" -> direction EventTitle where direction = if text == "id"…
amitaibu
  • 1,026
  • 1
  • 7
  • 23
-1
votes
1 answer

Localization in Yesod

I use the localization for application from yesod (module Text.Shakespeare.I18N). Below is example of code data STest = STest mkMessage "STest" "messages" ("ru") trMsg msg = renderMessage STest ["ru"] msg But if I want use several localization at…
QSpider
  • 537
  • 2
  • 10
-1
votes
1 answer

Yesod errors when compiling

For AForm I have got some compile errors: 1. For default Int value: data Person = Person { name :: Text , age :: Maybe Int } deriving Show formPerson :: AForm Handler Person formPerson = Person <$> areq textField "Person…
John Do
  • 15
  • 5
-1
votes
1 answer

Runnig Yesod Compiled Project on FpComplete using Amazon EC2

Hi sorry about this issue, i'm run out of ideas of how to access my deployed project on our main domain server. By following the Guidelines provided in the GitHub I installed properly the keter, put the .keter file in the /opt/keter/incoming path…
Ryan Monreal
  • 587
  • 5
  • 16
-2
votes
1 answer

Yesod and MySQL connection issue

I have been looking for a working example on the web to connect Yesod - Persistent to a MySQL db, and I found this resource on GitHub {-# LANGUAGE EmptyDataDecls #-} {-# LANGUAGE FlexibleContexts #-} {-# LANGUAGE GADTs …
FtheBuilder
  • 1,410
  • 12
  • 19
-2
votes
1 answer

Static route to uploaded files

I need to access a file in the static folder of Yesod, which gets uploaded there at runtime, so it does not have an identifier. Is there any way to construct a static route to such file?
nek0
  • 88
  • 7
-2
votes
2 answers

How to assign to mvar with case syntax?

I'am asking if i can add same think like that : if maVar == "false" then maVar = "" else maVar = maVar in tmy code haskell (yesod) let maVar= unpack $ case Map.lookup "maVarSession" sess of Just a -> a Nothing -> "Nothing"
-4
votes
1 answer

Making two widgets on one page in yesod

I need to add two widgets together in one page like this : getPageR :: Handler Html getPageR = defaultLayout $ do aDomId <- newIdent setTitle "Titre de la page" $(widgetFile "rightzone" ++ "leftzone") but this gives me a error.
1 2 3
88
89