コード例 #1
0
    def index(self):
        '''
        feeds are to be served as a file
        '''
        entries = ContentFactory().getArchive()
        # feeds need dates in RFC2822
        for entry in entries:
            # all changes to the entry should be here
            entry.date = RFC2822(entry.date)
            entry.url = 'http://pietisticmonk.com/blog/' + entry.url
        # publish date will be the latest post's date.
        pubdate = RFC2822(datetime.date.today().__str__())

        return render(file='templates/rss.xml')
コード例 #2
0
ファイル: feeds.py プロジェクト: GunioRobot/cherryblogger
    def index(self):
        '''
        feeds are to be served as a file
        '''
        entries = ContentFactory().getArchive()
        # feeds need dates in RFC2822
        for entry in entries:
            # all changes to the entry should be here
            entry.date = RFC2822(entry.date)
            entry.url = 'http://pietisticmonk.com/blog/' + entry.url
        # publish date will be the latest post's date.
        pubdate = RFC2822(datetime.date.today().__str__())

        return render(file='templates/rss.xml')
コード例 #3
0
ファイル: cache.py プロジェクト: GunioRobot/cherryblogger
 def index(self):
     action = "Cache Satus"
     stats = ContentFactory().cacheStatus()
     return render(file='templates/cache.html')
コード例 #4
0
ファイル: cache.py プロジェクト: GunioRobot/cherryblogger
 def clear(self, key=None):
     '''Clear Cache here'''
     action = str(ContentFactory().cacheClear(key))
     status = ContentFactory().cacheStatus()
     return render(file='templates/cache.html')
コード例 #5
0
ファイル: archive.py プロジェクト: GunioRobot/cherryblogger
 def index(self):
     entries = ContentFactory().getArchive()
     return render(file='templates/archive.html')
コード例 #6
0
ファイル: cache.py プロジェクト: GunioRobot/cherryblogger
 def index(self):
     action = "Cache Satus"
     stats = ContentFactory().cacheStatus()
     return render(file = 'templates/cache.html')
コード例 #7
0
ファイル: cache.py プロジェクト: GunioRobot/cherryblogger
 def clear(self, key=None):
     '''Clear Cache here'''
     action = str(ContentFactory().cacheClear(key))
     status = ContentFactory().cacheStatus()
     return render(file = 'templates/cache.html')
コード例 #8
0
ファイル: archive.py プロジェクト: GunioRobot/cherryblogger
 def index(self):
     entries = ContentFactory().getArchive()
     return render(file = 'templates/archive.html')
コード例 #9
0
ファイル: index.py プロジェクト: GunioRobot/cherryblogger
 def article(self, title=None):
     entry = ContentFactory().getEntry(title)
     return render(file = 'templates/article.html')