From 085bb88bb17af10f79aa3f2fbcef82166646d14c Mon Sep 17 00:00:00 2001 From: Michael Snoyman Date: Mon, 17 Jan 2011 08:14:50 +0200 Subject: [PATCH] Include some RSS-specific definitions --- Yesod/Content.hs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Yesod/Content.hs b/Yesod/Content.hs index f65a0458..9b026de7 100644 --- a/Yesod/Content.hs +++ b/Yesod/Content.hs @@ -19,6 +19,7 @@ module Yesod.Content , typeJson , typeXml , typeAtom + , typeRss , typeJpeg , typePng , typeGif @@ -45,6 +46,7 @@ module Yesod.Content -- * Utilities , formatW3 , formatRFC1123 + , formatRFC822 #if TEST , contentTestSuite #endif @@ -194,6 +196,9 @@ typeXml = "text/xml" typeAtom :: ContentType typeAtom = "application/atom+xml" +typeRss :: ContentType +typeRss = "application/rss+xml" + typeJpeg :: ContentType typeJpeg = "image/jpeg" @@ -271,3 +276,7 @@ formatW3 = formatTime defaultTimeLocale "%FT%X-00:00" -- | Format as per RFC 1123. formatRFC1123 :: UTCTime -> String formatRFC1123 = formatTime defaultTimeLocale "%a, %d %b %Y %X %Z" + +-- | Format as per RFC 822. +formatRFC822 :: UTCTime -> String +formatRFC822 = formatTime defaultTimeLocale "%a, %d %b %Y %H:%M:%S %z"