summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEvgeny Fadeev <evgeny.fadeev@gmail.com>2012-06-02 21:30:05 -0400
committerEvgeny Fadeev <evgeny.fadeev@gmail.com>2012-06-02 21:30:05 -0400
commit995e6714f63f8c11318019a8f63a6fdb2a664a41 (patch)
treed6ea35e181d11c8ae742bd72d64ccdc4fbf091ff
parent804b84e448d43f3e2adc9d4bbc21c081d468bb49 (diff)
downloadaskbot-995e6714f63f8c11318019a8f63a6fdb2a664a41.tar.gz
askbot-995e6714f63f8c11318019a8f63a6fdb2a664a41.tar.bz2
askbot-995e6714f63f8c11318019a8f63a6fdb2a664a41.zip
added optional top banner to the question page
-rw-r--r--askbot/conf/sidebar_question.py20
-rw-r--r--askbot/doc/source/changelog.rst1
-rw-r--r--askbot/skins/default/templates/question.html3
3 files changed, 21 insertions, 3 deletions
diff --git a/askbot/conf/sidebar_question.py b/askbot/conf/sidebar_question.py
index 4416823d..bb71be7e 100644
--- a/askbot/conf/sidebar_question.py
+++ b/askbot/conf/sidebar_question.py
@@ -6,21 +6,35 @@ from askbot.deps.livesettings import ConfigurationGroup
from askbot.deps.livesettings import values
from django.utils.translation import ugettext as _
from askbot.conf.super_groups import CONTENT_AND_UI
-SIDEBAR_QUESTION = ConfigurationGroup(
+SIDEBAR_QUESTION = ConfigurationGroup(#shitty name - why sidebar?
'SIDEBAR_QUESTION',
- _('Question page sidebar'),
+ _('Question page banners and sidebar'),
super_group = CONTENT_AND_UI
)
settings.register(
values.LongStringValue(
SIDEBAR_QUESTION,
+ 'QUESTION_PAGE_TOP_BANNER',
+ description = _('Top banner'),
+ default = '',
+ help_text = _(
+ 'When using this option, please '
+ 'use the HTML validation service to make sure that '
+ 'your input is valid and works well in all browsers.'
+ )
+ )
+)
+
+settings.register(
+ values.LongStringValue(
+ SIDEBAR_QUESTION,
'SIDEBAR_QUESTION_HEADER',
description = _('Custom sidebar header'),
default = '',
help_text = _(
'Use this area to enter content at the TOP of the sidebar'
- 'in HTML format. When using this option '
+ 'in HTML format. When using this option '
'(as well as the sidebar footer), please '
'use the HTML validation service to make sure that '
'your input is valid and works well in all browsers.'
diff --git a/askbot/doc/source/changelog.rst b/askbot/doc/source/changelog.rst
index 7d1a2fc0..f1fe22e2 100644
--- a/askbot/doc/source/changelog.rst
+++ b/askbot/doc/source/changelog.rst
@@ -7,6 +7,7 @@ In development
to help prevent user profile spam (Evgeny)
* Added a function to create a custom user profile tab,
the feature requires access to the server (Evgeny)
+* Added optional top banner to the question page (Evgeny)
0.7.43 (May 14, 2012)
---------------------
diff --git a/askbot/skins/default/templates/question.html b/askbot/skins/default/templates/question.html
index f22796db..741b4bf4 100644
--- a/askbot/skins/default/templates/question.html
+++ b/askbot/skins/default/templates/question.html
@@ -156,6 +156,9 @@
</script>
{% endblock %}
{% block content %}
+ <div>
+ {{ settings.QUESTION_PAGE_TOP_BANNER }}
+ </div>
{% if is_cacheable %}
{% cache long_time "thread-content-html" thread.id %}
{% include "question/content.html" %}