26. HSP(Haskell Server Pages) EmbededなXMLコード page :: (?a :: Application, ?s :: Session) => Element page = <HTML> <TITLE>Counter</TITLE> <BODY> <P> This page has been accessed <% do{ n <- countPage ; return [ <IMG SRC=(i:".gif") /> | i <- show n ] } %> times. </P> <P> You have visited this page <% countSession %> times. </P> </BODY> </HTML>
45. Heiste例 <bind tag="longname"> Einstein, Feynman, Heisenberg, and Newton Research Corporation Ltd.<sup>TM</sup></bind><p> We at <longname/> have research expertise in many areas of physics. Employment at <longname/> carries significant prestige. The rigorous hiring process developed by <longname/> is leading the industry.</p>
59. Web Route Quasi <Foundation>.hs QuasiQuoteでパスを作成 mkYesodData"Test" [$parseRoutes| /static StaticR Static getStatic /authAuthRAuthgetAuth /favicon.ico FaviconR GET /robots.txt RobotsRGET / RootR GET /user/#String/configConfigR GET POST /user/#String/post/#IntPostR POST |]
62. persistent例 share2 mkPersist (mkMigrate "migrateAll") [persist| User ident String name String Update password String Maybe Update longName String Update default="" desc Text Update default="" UniqueUserident UniqueUserName name Post user UserIdEq In content Text replyToPostId Maybe replyToUserUserId Maybe date UTCTimeDesc |]