If you explicitly want to avoid JavaScript / XHR you could use a meta refresh attribute in your HTML page:
http://en.m.wikipedia.org/wiki/Meta_refresh
Cheers,
Ben
Hi, please is there a way how I could autorefresh / reload the page in scotty?A small example, where I would like to see that the time refreshes every second:{-# LANGUAGE OverloadedStrings #-}import Web.Scottyimport Control.Monad.Trans (liftIO)import qualified Data.Text.Lazy as L (Text, pack)
import Data.Time.Clockmain = scotty 3005 $ doget "/" $ dotime <- liftIO getTimehtml timegetTime :: IO L.TextgetTime = doutcTime <- getCurrentTimelet timeText = L.pack $ show utcTimereturn timeTextCheers,M.
_______________________________________________
Beginners mailing list
Beginners@haskell.org
http://www.haskell.org/mailman/listinfo/beginners