Append domain_name in pages title
This commit is contained in:
14
display.py
14
display.py
@@ -27,6 +27,12 @@ import logging
|
||||
# Create output HTML files
|
||||
#
|
||||
|
||||
# Just for detection
|
||||
def _(name): pass
|
||||
_('January'), _('February'), _('March'), _('April'), _('May'), _('June'), _('July')
|
||||
_('August'), _('September'), _('October'), _('November'), _('December')
|
||||
del _
|
||||
|
||||
class DisplayHTMLRaw(object):
|
||||
|
||||
def __init__(self, iwla, html=u''):
|
||||
@@ -370,6 +376,12 @@ def generateHTMLLink(url, name=None, max_length=100, prefix=u'http'):
|
||||
return u'<a href="%s">%s</a>' % (url, name[:max_length])
|
||||
|
||||
def createCurTitle(iwla, title):
|
||||
title = iwla._(title) + time.strftime(u' - %B %Y', iwla.getCurTime())
|
||||
title = iwla._(title)
|
||||
month_name = time.strftime(u'%B', iwla.getCurTime())
|
||||
year = time.strftime(u'%Y', iwla.getCurTime())
|
||||
title += u' - %s %s' % (iwla._(month_name), year)
|
||||
domain_name = iwla.getConfValue('domain_name', '')
|
||||
if domain_name:
|
||||
title += u' - %s' % (domain_name)
|
||||
return title
|
||||
|
||||
|
||||
Reference in New Issue
Block a user