From 174c53e97bcf1e5412c141829d152aa5a2b8684c Mon Sep 17 00:00:00 2001 From: hernani Date: Sat, 12 Jun 2010 01:16:53 +0000 Subject: [PATCH] Adds a new function in the profile menu for admins to suspend users, indefinetly or for a pre-determined period of time. git-svn-id: http://svn.osqa.net/svnroot/osqa/trunk@411 0cfe37f9-358a-4d5e-be75-b63607b5c754 --- forum/actions/user.py | 26 + forum/http_responses.py | 15 + forum/middleware/extended_user.py | 10 +- forum/middleware/request_utils.py | 9 +- forum/models/user.py | 73 +- forum/skins/default/media/js/osqa.user.js | 45 +- forum/skins/default/media/style/style.css | 1752 ++++++++++------- forum/skins/default/templates/403.html | 47 + forum/skins/default/templates/404.html | 4 +- .../default/templates/{410.html => 503.html} | 0 .../default/templates/node/comments.html | 4 +- .../templates/node/contributors_info.html | 4 +- .../templates/osqaadmin/djstyle_base.html | 1 + .../templates/osqaadmin/moderation.html | 101 + forum/skins/default/templates/users/menu.html | 61 +- .../default/templates/users/signature.html | 55 +- .../default/templates/users/suspend_user.html | 49 + .../skins/default/templates/users/users.html | 8 +- forum/templatetags/extra_tags.py | 3 + forum/urls.py | 268 +-- forum/views/admin.py | 79 +- forum/views/auth.py | 31 +- forum/views/commands.py | 138 +- forum/views/decorators.py | 49 +- forum/views/users.py | 148 +- forum_modules/localauth/forms.py | 24 +- 26 files changed, 1842 insertions(+), 1162 deletions(-) create mode 100644 forum/http_responses.py create mode 100644 forum/skins/default/templates/403.html rename forum/skins/default/templates/{410.html => 503.html} (100%) create mode 100644 forum/skins/default/templates/osqaadmin/moderation.html create mode 100644 forum/skins/default/templates/users/suspend_user.html diff --git a/forum/actions/user.py b/forum/actions/user.py index f76a281..a3856a8 100644 --- a/forum/actions/user.py +++ b/forum/actions/user.py @@ -102,4 +102,30 @@ class AwardAction(ActionProxy): 'user': self.hyperlink(self.user.get_profile_url(), self.friendly_username(viewer, self.user)), 'were_was': self.viewer_or_user_verb(viewer, self.user, _('were'), _('was')), 'badge_name': self.award.badge.name, + } + +class SuspendAction(ActionProxy): + def process_data(self, **kwargs): + self.extra = kwargs + + def process_action(self): + self.user.is_active = False + self.user.save() + + def cancel_action(self): + self.user.is_active = True + self.user._pop_suspension_cache() + self.user.save() + self.user.message_set.create(message=_("Your suspension has been removed.")) + + def describe(self, viewer=None): + if self.extra.get('bantype', 'indefinitely') == 'forxdays' and self.extra.get('forxdays', None): + suspension = _("for %s days") % self.extra['forxdays'] + else: + suspension = _("indefinetely") + + return _("%(user)s %(were_was)s suspended %(suspension)s: %(msg)s") % { + 'user': self.hyperlink(self.user.get_profile_url(), self.friendly_username(viewer, self.user)), + 'were_was': self.viewer_or_user_verb(viewer, self.user, _('were'), _('was')), + 'suspension': suspension, 'msg': self.extra.get('publicmsg', _('Bad behaviour')) } \ No newline at end of file diff --git a/forum/http_responses.py b/forum/http_responses.py new file mode 100644 index 0000000..42bef58 --- /dev/null +++ b/forum/http_responses.py @@ -0,0 +1,15 @@ +from django.http import HttpResponse +from django.template.loader import render_to_string + +from forum import settings + +class HttpResponseServiceUnavailable(HttpResponse): + def __init__(self, message): + super(HttpResponseServiceUnavailable, self).__init__(content=render_to_string('503.html', { + 'message': message, + 'app_logo': settings.APP_LOGO, + 'app_title': settings.APP_TITLE + }), status=503) + +class HttpResponseUnauthorized(HttpResponse): + pass \ No newline at end of file diff --git a/forum/middleware/extended_user.py b/forum/middleware/extended_user.py index e54c9b4..0e44f73 100644 --- a/forum/middleware/extended_user.py +++ b/forum/middleware/extended_user.py @@ -1,12 +1,20 @@ from django.contrib.auth.middleware import AuthenticationMiddleware +from django.contrib.auth import logout from forum.models.user import AnonymousUser +from forum.views.auth import forward_suspended_user -class ExtendedUser(AuthenticationMiddleware): +class ExtendedUser(AuthenticationMiddleware): def process_request(self, request): super(ExtendedUser, self).process_request(request) if request.user.is_authenticated(): try: request.user = request.user.user + + if request.user.is_suspended(): + user = request.user + logout(request) + return forward_suspended_user(request, user) + return None except: pass diff --git a/forum/middleware/request_utils.py b/forum/middleware/request_utils.py index 46d56b7..40736bf 100644 --- a/forum/middleware/request_utils.py +++ b/forum/middleware/request_utils.py @@ -1,7 +1,6 @@ from forum.settings import MAINTAINANCE_MODE, APP_LOGO, APP_TITLE -from django.http import HttpResponseGone -from django.template.loader import render_to_string +from forum.http_responses import HttpResponseServiceUnavailable class RequestUtils(object): def __init__(self): @@ -31,11 +30,7 @@ class RequestUtils(object): ip = request.META['REMOTE_ADDR'] if not ip in MAINTAINANCE_MODE.value['allow_ips']: - return HttpResponseGone(render_to_string('410.html', { - 'message': MAINTAINANCE_MODE.value.get('message', ''), - 'app_logo': APP_LOGO, - 'app_title': APP_TITLE - })) + return HttpResponseServiceUnavailable(MAINTAINANCE_MODE.value.get('message', '')) if request.session.get('redirect_POST_data', None): request.POST = request.session.pop('redirect_POST_data') diff --git a/forum/models/user.py b/forum/models/user.py index f027ffa..8837ef3 100644 --- a/forum/models/user.py +++ b/forum/models/user.py @@ -1,4 +1,5 @@ from base import * +from django.core.exceptions import ObjectDoesNotExist, MultipleObjectsReturned from django.contrib.contenttypes.models import ContentType from django.contrib.auth.models import User as DjangoUser, AnonymousUser as DjangoAnonymousUser from django.db.models import Q @@ -11,13 +12,12 @@ import string from random import Random from django.utils.translation import ugettext as _ -import django.dispatch - +import logging QUESTIONS_PER_PAGE_CHOICES = ( - (10, u'10'), - (30, u'30'), - (50, u'50'), +(10, u'10'), +(30, u'30'), +(50, u'50'), ) class UserManager(CachedManager): @@ -91,6 +91,7 @@ class AnonymousUser(DjangoAnonymousUser): def true_if_is_super_or_staff(fn): def decorated(self, *args, **kwargs): return self.is_superuser or self.is_staff or fn(self, *args, **kwargs) + return decorated class User(BaseModel, DjangoUser): @@ -101,7 +102,7 @@ class User(BaseModel, DjangoUser): gold = models.PositiveIntegerField(default=0) silver = models.PositiveIntegerField(default=0) bronze = models.PositiveIntegerField(default=0) - + last_seen = models.DateTimeField(default=datetime.datetime.now) real_name = models.CharField(max_length=100, blank=True) website = models.URLField(max_length=200, blank=True) @@ -113,7 +114,7 @@ class User(BaseModel, DjangoUser): vote_up_count = DenormalizedField("actions", canceled=False, action_type="voteup") vote_down_count = DenormalizedField("actions", canceled=False, action_type="votedown") - + objects = UserManager() def __unicode__(self): @@ -155,7 +156,7 @@ class User(BaseModel, DjangoUser): return self.get_profile_url() def get_profile_link(self): - profile_link = u'%s' % (self.get_profile_url(),self.username) + profile_link = u'%s' % (self.get_profile_url(), self.username) return mark_safe(profile_link) def get_visible_answers(self, question): @@ -164,11 +165,12 @@ class User(BaseModel, DjangoUser): def get_vote_count_today(self): today = datetime.date.today() return self.actions.filter(canceled=False, action_type__in=("voteup", "votedown"), - action_date__gte=(today - datetime.timedelta(days=1))).count() + action_date__gte=(today - datetime.timedelta(days=1))).count() def get_reputation_by_upvoted_today(self): today = datetime.datetime.now() - sum = self.reputes.filter(reputed_at__range=(today - datetime.timedelta(days=1), today)).aggregate(models.Sum('value')) + sum = self.reputes.filter(reputed_at__range=(today - datetime.timedelta(days=1), today)).aggregate( + models.Sum('value')) #todo: redo this, maybe transform in the daily cap #if sum.get('value__sum', None) is not None: return sum['value__sum'] return 0 @@ -176,7 +178,7 @@ class User(BaseModel, DjangoUser): def get_flagged_items_count_today(self): today = datetime.date.today() return self.actions.filter(canceled=False, action_type="flag", - action_date__gte=(today - datetime.timedelta(days=1))).count() + action_date__gte=(today - datetime.timedelta(days=1))).count() @true_if_is_super_or_staff def can_view_deleted_post(self, post): @@ -204,7 +206,7 @@ class User(BaseModel, DjangoUser): @true_if_is_super_or_staff def can_comment(self, post): return self == post.author or self.reputation >= int(settings.REP_TO_COMMENT - ) or (post.__class__.__name__ == "Answer" and self == post.question.author) + ) or (post.__class__.__name__ == "Answer" and self == post.question.author) @true_if_is_super_or_staff def can_like_comment(self, comment): @@ -220,7 +222,8 @@ class User(BaseModel, DjangoUser): return self == comment.author or self.reputation >= int(settings.REP_TO_DELETE_COMMENTS) def can_convert_to_comment(self, answer): - return (not answer.marked) and (self.is_superuser or self.is_staff or answer.author == self or self.reputation >= int(settings.REP_TO_CONVERT_TO_COMMENT)) + return (not answer.marked) and (self.is_superuser or self.is_staff or answer.author == self or self.reputation >= int + (settings.REP_TO_CONVERT_TO_COMMENT)) @true_if_is_super_or_staff def can_accept_answer(self, answer): @@ -233,7 +236,8 @@ class User(BaseModel, DjangoUser): @true_if_is_super_or_staff def can_edit_post(self, post): return self == post.author or self.reputation >= int(settings.REP_TO_EDIT_OTHERS - ) or (post.nis.wiki and self.reputation >= int(settings.REP_TO_EDIT_WIKI)) + ) or (post.nis.wiki and self.reputation >= int( + settings.REP_TO_EDIT_WIKI)) @true_if_is_super_or_staff def can_wikify(self, post): @@ -260,9 +264,9 @@ class User(BaseModel, DjangoUser): def can_delete_post(self, post): if post.node_type == "comment": return self.can_delete_comment(post) - + return (self == post.author and (post.__class__.__name__ == "Answer" or - not post.answers.exclude(author=self).count())) + not post.answers.exclude(author=self).count())) @true_if_is_super_or_staff def can_upload_files(self): @@ -272,6 +276,35 @@ class User(BaseModel, DjangoUser): self.__dict__.update(self.__class__.objects.filter(id=self.id).values('password')[0]) return DjangoUser.check_password(self, old_passwd) + @property + def suspension(self): + if self.__dict__.get('_suspension_dencache_', False) != None: + try: + self.__dict__['_suspension_dencache_'] = self.actions.get(action_type="suspend", canceled=False) + except ObjectDoesNotExist: + self.__dict__['_suspension_dencache_'] = None + except MultipleObjectsReturned: + logging.error("Multiple suspension actions found for user %s (%s)" % (self.username, self.id)) + self.__dict__['_suspension_dencache_'] = self.actions.filter(action_type="suspend", canceled=False + ).order_by('-action_date')[0] + + return self.__dict__['_suspension_dencache_'] + + def _pop_suspension_cache(self): + self.__dict__.pop('_suspension_dencache_', None) + + def is_suspended(self): + if not self.is_active: + suspension = self.suspension + + if suspension and suspension.extra.get('bantype', None) == 'forxdays' and ( + datetime.datetime.now() > suspension.action_date + datetime.timedelta( + days=int(suspension.extra.get('forxdays', 365)))): + suspension.cancel() + else: + return True + + return False class Meta: app_label = 'forum' @@ -286,7 +319,7 @@ class SubscriptionSettings(models.Model): new_question = models.CharField(max_length=1, default='d') new_question_watched_tags = models.CharField(max_length=1, default='i') subscribed_questions = models.CharField(max_length=1, default='i') - + #auto_subscribe_to all_questions = models.BooleanField(default=False) all_questions_watched_tags = models.BooleanField(default=False) @@ -324,7 +357,7 @@ class ValidationHashManager(models.Manager): obj.save() except: return None - + return obj def validate(self, hash, user, type, hash_data=[]): @@ -352,7 +385,7 @@ class ValidationHashManager(models.Manager): return False class ValidationHash(models.Model): - hash_code = models.CharField(max_length=255,unique=True) + hash_code = models.CharField(max_length=255, unique=True) seed = models.CharField(max_length=12) expiration = models.DateTimeField(default=one_day_from_now) type = models.CharField(max_length=12) @@ -368,7 +401,7 @@ class ValidationHash(models.Model): return self.hash_code class AuthKeyUserAssociation(models.Model): - key = models.CharField(max_length=255,null=False,unique=True) + key = models.CharField(max_length=255, null=False, unique=True) provider = models.CharField(max_length=64) user = models.ForeignKey(User, related_name="auth_keys") added_at = models.DateTimeField(default=datetime.datetime.now) diff --git a/forum/skins/default/media/js/osqa.user.js b/forum/skins/default/media/js/osqa.user.js index 6450c3c..5241880 100644 --- a/forum/skins/default/media/js/osqa.user.js +++ b/forum/skins/default/media/js/osqa.user.js @@ -1,13 +1,13 @@ $().ready(function() { var $dropdown = $('#user-menu-dropdown'); - $('#user-menu').click(function(){ + $('#user-menu').click(function() { $('.dialog').fadeOut('fast', function() { $dialog.remove(); }); $dropdown.slideToggle('fast', function() { if ($dropdown.is(':visible')) { - $dropdown.one('clickoutside', function() { + $dropdown.one('clickoutside', function() { $dropdown.slideUp('fast') }); } @@ -43,30 +43,31 @@ $().ready(function() { + '' + messages.message + ''; show_dialog({ - html: table, - extra_class: 'award-rep-points', - event: e, - yes_callback: function($dialog) { - var $points_input = $('#points-to-award'); - var _points = parseInt($points_input.val()); + html: table, + extra_class: 'award-rep-points', + event: e, + yes_callback: function($dialog) { + var $points_input = $('#points-to-award'); + var _points = parseInt($points_input.val()); - if(!isNaN(_points)) { - $dialog.fadeOut('fast'); - var _message = $('#award-message').val(); - $.post($('#award-rep-points').attr('href'), {points: _points, message: _message}, function(data) { - if (data.success) { - $('#user-reputation').css('background', 'yellow'); - $('#user-reputation').html(data.reputation); + if (!isNaN(_points)) { + $dialog.fadeOut('fast'); + var _message = $('#award-message').val(); + $.post($('#award-rep-points').attr('href'), {points: _points, message: _message}, function(data) { + if (data.success) { + $('#user-reputation').css('background', 'yellow'); + $('#user-reputation').html(data.reputation); - $('#user-reputation').animate({ backgroundColor: "transparent" }, 1000); + $('#user-reputation').animate({ backgroundColor: "transparent" }, 1000); - } - }, 'json') - } - }, - show_no: true - }); + } + }, 'json') + } + }, + show_no: true + }); return false; }); + }); \ No newline at end of file diff --git a/forum/skins/default/media/style/style.css b/forum/skins/default/media/style/style.css index 28bd8f3..dc32123 100644 --- a/forum/skins/default/media/style/style.css +++ b/forum/skins/default/media/style/style.css @@ -1,353 +1,390 @@ @import "jquery.autocomplete.css"; body { - background: none repeat scroll 0 0 #FFFFFF; - color: #000000; - font-family: sans-serif; - font-size: 12px; - line-height: 150%; - margin: 0; - padding: 0; + background: none repeat scroll 0 0 #FFFFFF; + color: #000000; + font-family: sans-serif; + font-size: 12px; + line-height: 150%; + margin: 0; + padding: 0; } div { - margin: 0 auto; - padding: 0; + margin: 0 auto; + padding: 0; } -h1,h2,h3,ul,li,form,img,p { - border: medium none; - margin: 0; - padding: 0; +h1, h2, h3, ul, li, form, img, p { + border: medium none; + margin: 0; + padding: 0; } -label {vertical-align: middle;} +label { + vertical-align: middle; +} -.login label {display: block;} -.login .form-row-vertical {margin-bottom: 8px;} +.login label { + display: block; +} + +.login .form-row-vertical { + margin-bottom: 8px; +} hr { - border-color: #CCCCCE -moz-use-text-color -moz-use-text-color; - border-right: medium none; - border-style: dashed none none; - border-width: 1px medium medium; + border-color: #CCCCCE -moz-use-text-color -moz-use-text-color; + border-right: medium none; + border-style: dashed none none; + border-width: 1px medium medium; } -input,select { - font-family: Trebuchet MS,"segoe ui",Helvetica,"Microsoft YaHei",Tahoma,Verdana,MingLiu,PMingLiu,Arial,sans-serif; - vertical-align: middle; +input, select { + font-family: Trebuchet MS, "segoe ui", Helvetica, "Microsoft YaHei", Tahoma, Verdana, MingLiu, PMingLiu, Arial, sans-serif; + vertical-align: middle; } p { - font-size: 13px; - line-height: 140%; - margin-bottom: 13px; + font-size: 13px; + line-height: 140%; + margin-bottom: 13px; } a { - color: #3060A8; - text-decoration: none; + color: #3060A8; + text-decoration: none; } .badges a { - color: #763333; - text-decoration: underline; + color: #763333; + text-decoration: underline; +} + +a:hover { + text-decoration: underline; } -a:hover { text-decoration: underline; } -.tright { text-align: right; } +.tright { + text-align: right; +} .spacer3 { - clear: both; - height: 30px; - line-height: 30px; - visibility: hidden; + clear: both; + height: 30px; + line-height: 30px; + visibility: hidden; } h1 { - font-size: 160%; - padding: 5px 0; + font-size: 160%; + padding: 5px 0; line-height: 110%; } h2 { - font-size: 140%; - padding: 3px 0; + font-size: 140%; + padding: 3px 0; line-height: 110%; } h3 { - font-size: 120%; - padding: 3px 0; - line-height: 110%; + font-size: 120%; + padding: 3px 0; + line-height: 110%; } ul { - list-style: disc outside none; - margin-bottom: 1em; - margin-left: 20px; - padding-left: 0; + list-style: disc outside none; + margin-bottom: 1em; + margin-left: 20px; + padding-left: 0; } ol { - list-style: decimal outside none; - margin-bottom: 1em; - margin-left: 30px; - padding-left: 0; + list-style: decimal outside none; + margin-bottom: 1em; + margin-left: 30px; + padding-left: 0; +} + +td ul { + vertical-align: middle; } -td ul { vertical-align: middle; } -li input { margin: 3px 3px 4px; } +li input { + margin: 3px 3px 4px; +} pre { - background-color: #F5F5F5; - font-family: Consolas,Monaco,Liberation Mono,Lucida Console,Monospace; - font-size: 100%; - margin-bottom: 10px; - overflow: auto; - padding-left: 5px; - padding-top: 5px; - width: 580px; + background-color: #F5F5F5; + font-family: Consolas, Monaco, Liberation Mono, Lucida Console, Monospace; + font-size: 100%; + margin-bottom: 10px; + overflow: auto; + padding-left: 5px; + padding-top: 5px; + width: 580px; } code { - font-family: Consolas,Monaco,Liberation Mono,Lucida Console,Monospace; - font-size: 100%; + font-family: Consolas, Monaco, Liberation Mono, Lucida Console, Monospace; + font-size: 100%; } blockquote { - background-color: #F5F5F5; - margin-bottom: 10px; - margin-right: 15px; - padding: 10px 0 1px 10px; + background-color: #F5F5F5; + margin-bottom: 10px; + margin-right: 15px; + padding: 10px 0 1px 10px; } #wrapper { - margin: auto; - padding: 0; - width: 990px; + margin: auto; + padding: 0; + width: 990px; } #roof { - background: none repeat scroll 0 0 #FFFFFF; - margin-top: 0; - position: relative; + background: none repeat scroll 0 0 #FFFFFF; + margin-top: 0; + position: relative; } #room { - background-color: #FFFFFF; - border-bottom: 1px solid #777777; - padding: 10px 0; + background-color: #FFFFFF; + border-bottom: 1px solid #777777; + padding: 10px 0; } #CALeft { - float: left; - position: relative; - width: 740px; + float: left; + position: relative; + width: 740px; } #CARight { - float: right; - width: 240px; + float: right; + width: 240px; } #CAFull { - float: left; - padding: 0 5px; - width: 950px; + float: left; + padding: 0 5px; + width: 950px; } #ground { - background: none repeat scroll 0 0 #BDCCED; - border-top: 1px solid #000000; - padding-bottom: 0; - padding-top: 6px; - text-align: center; - width: 100%; + background: none repeat scroll 0 0 #BDCCED; + border-top: 1px solid #000000; + padding-bottom: 0; + padding-top: 6px; + text-align: center; + width: 100%; } #top { - background-color: #FFFFFF; - height: 20px; - padding: 3px; - position: absolute; - right: 0; - text-align: right; - top: 0; - width: 500px; + background-color: #FFFFFF; + height: 20px; + padding: 3px; + position: absolute; + right: 0; + text-align: right; + top: 0; + width: 500px; } #top a { - color: #333333; - font-size: 12px; - height: 35px; - margin-left: 20px; - text-align: right; - text-decoration: underline; + color: #333333; + font-size: 12px; + height: 35px; + margin-left: 20px; + text-align: right; + text-decoration: underline; } -#logo { padding: 5px 0 0; } +#logo { + padding: 5px 0 0; +} #navBar { - display: block; - position: relative; - width: 990px; + display: block; + position: relative; + width: 990px; } -#navBar .nav { margin: 20px 0 0 16px; } +#navBar .nav { + margin: 20px 0 0 16px; +} #navBar .nav a { - background-color: #E5EBF8; - border-color: #888888 #888888 -moz-use-text-color; - border-style: solid solid none; - border-width: 1px 1px medium; - color: #333333; - display: block; - float: left; - font-size: 14px; - font-weight: 400; - height: 25px; - line-height: 30px; - margin-left: 10px; - padding: 0 12px 3px; - text-decoration: none; -} - -#navBar .nav a:hover { text-decoration: underline; } + background-color: #E5EBF8; + border-color: #888888 #888888 -moz-use-text-color; + border-style: solid solid none; + border-width: 1px 1px medium; + color: #333333; + display: block; + float: left; + font-size: 14px; + font-weight: 400; + height: 25px; + line-height: 30px; + margin-left: 10px; + padding: 0 12px 3px; + text-decoration: none; +} + +#navBar .nav a:hover { + text-decoration: underline; +} #navBar .nav a.on { - background: none repeat scroll 0 0 #356FCB; - border: 1px solid #356FCB; - color: #FFFFFF; - font-weight: 600; - height: 24px; - line-height: 28px; - text-decoration: none; + background: none repeat scroll 0 0 #356FCB; + border: 1px solid #356FCB; + color: #FFFFFF; + font-weight: 600; + height: 24px; + line-height: 28px; + text-decoration: none; } #navBar .nav a.special { - color: #B02B2C; - font-size: 14px; - font-weight: bold; - text-decoration: none; + color: #B02B2C; + font-size: 14px; + font-weight: bold; + text-decoration: none; } -#navBar .nav a.special:hover { text-decoration: underline; } +#navBar .nav a.special:hover { + text-decoration: underline; +} #navBar .nav div.focus { - float: right; - padding-right: 0; + float: right; + padding-right: 0; } #searchBar { - background-color: #B6C4E2; - border-color: #EEEEEC #A9ACA5 #BABDB6 #EEEEEC; - border-style: solid; - border-width: 1px; - padding: 4px 0 0; - width: 988px; + background-color: #B6C4E2; + border-color: #EEEEEC #A9ACA5 #BABDB6 #EEEEEC; + border-style: solid; + border-width: 1px; + padding: 4px 0 0; + width: 988px; } -#searchBar .content { } +#searchBar .content { +} #searchBar .searchInput { - font-size: 13px; - height: 18px; - width: 400px; + font-size: 13px; + height: 18px; + width: 400px; } #searchBar .searchBtn { - font-size: 14px; - height: 26px; - width: 80px; + font-size: 14px; + height: 26px; + width: 80px; } #searchBar .options { - color: #333333; - font-size: 120%; - padding: 3px 0; + color: #333333; + font-size: 120%; + padding: 3px 0; +} + +#searchBar .options input { + margin: 0 3px 0 15px; } -#searchBar .options input { margin: 0 3px 0 15px; } -#searchBar .options input:hover { cursor: pointer; } +#searchBar .options input:hover { + cursor: pointer; +} #listA { - background-color: #FFFFFF; - float: left; - padding: 0 0; - width: 100%; + background-color: #FFFFFF; + float: left; + padding: 0 0; + width: 100%; } .thousand { - color: orange; + color: orange; } .short-summary { - border-top: 1px dotted #CCCCCE; - float: left; - overflow: hidden; - padding: 3px 0px 5px 0; - position: relative; - width: 740px; + border-top: 1px dotted #CCCCCE; + float: left; + overflow: hidden; + padding: 3px 0px 5px 0; + position: relative; + width: 740px; } .short-summary h2 a { - color: #2A5594; - font-family: "Trebuchet MS","segoe ui",arial,sans-serif; - font-size: 17px; + color: #2A5594; + font-family: "Trebuchet MS", "segoe ui", arial, sans-serif; + font-size: 17px; } .short-summary .userinfo { - color: #666666; - float: right; - margin-top: 8px; + color: #666666; + float: right; + margin-top: 8px; } -.userinfo a,a.userinfo { color: #3060A8; } +.userinfo a, a.userinfo { + color: #3060A8; +} .short-summary .counts { - float: left; - margin-right: 0px; - margin-top: 4px; - padding-right: 2px; + float: left; + margin-right: 0px; + margin-top: 4px; + padding-right: 2px; } .short-summary .counts .item-count { - font-size: 17px; - font-weight: bold; + font-size: 17px; + font-weight: bold; } -.short-summary .votes,.short-summary .status,.short-summary .views { - -moz-border-radius: 5px 5px 5px 5px; - border-bottom: 1px solid #CCCCCC; - border-right: 1px solid #CCCCCC; - float: left; - font-size: 11px; - height: 42px; - margin: 0 6px 0 0px; - padding: 8px 2px 0; - text-align: center; - width: 46px; +.short-summary .votes, .short-summary .status, .short-summary .views { + -moz-border-radius: 5px 5px 5px 5px; + border-bottom: 1px solid #CCCCCC; + border-right: 1px solid #CCCCCC; + float: left; + font-size: 11px; + height: 42px; + margin: 0 6px 0 0px; + padding: 8px 2px 0; + text-align: center; + width: 46px; } -.short-summary .votes,.short-summary .views { color: #666666; } +.short-summary .votes, .short-summary .views { + color: #666666; +} .short-summary .favorites { - width: 24px; - float: left; - text-align: center; + width: 24px; + float: left; + text-align: center; } -#question-table { margin-bottom: 10px; } +#question-table { + margin-bottom: 10px; +} .questions-count { - color: #A40000; - font-family: sans-serif; - font-size: 24px; - font-weight: 600; - margin-top: 3px; + color: #A40000; + font-family: sans-serif; + font-size: 24px; + font-weight: 600; + margin-top: 3px; margin-right: 5px; - padding: 0 0 5px 0; + padding: 0 0 5px 0; } .boxA { @@ -357,819 +394,975 @@ blockquote { } .boxA h3 { - color: #FFFFFF; - font-size: 13px; - font-weight: 800; - margin: 0 0 4px; - padding: 0; + color: #FFFFFF; + font-size: 13px; + font-weight: 800; + margin: 0 0 4px; + padding: 0; } .boxA .body { - background: none repeat scroll 0 0 #FFFFFF; - border: 1px solid #999999; - font-size: 13px; - padding: 8px; + background: none repeat scroll 0 0 #FFFFFF; + border: 1px solid #999999; + font-size: 13px; + padding: 8px; } .boxA .more { - font-weight: 800; - padding: 2px; - text-align: right; + font-weight: 800; + padding: 2px; + text-align: right; } .boxC { - background: none repeat scroll 0 0 #E5EBF8; - border-color: #EEEEEC #A9ACA5 #BABDB6 #EEEEEC; - border-style: solid; - border-width: 1px; - margin-bottom: 8px; - padding: 10px; + background: none repeat scroll 0 0 #E5EBF8; + border-color: #EEEEEC #A9ACA5 #BABDB6 #EEEEEC; + border-style: solid; + border-width: 1px; + margin-bottom: 8px; + padding: 10px; +} + +.boxC p { + margin-bottom: 8px; } -.boxC p { margin-bottom: 8px; } -.boxC p.nomargin { margin: 0; } +.boxC p.nomargin { + margin: 0; +} .boxC p.info-box-follow-up-links { - margin: 0; - text-align: right; + margin: 0; + text-align: right; } .pager { - float: left; - margin-bottom: 16px; - margin-top: 10px; + float: left; + margin-bottom: 16px; + margin-top: 10px; } .pagesize { - float: right; - margin-bottom: 16px; - margin-top: 10px; + float: right; + margin-bottom: 16px; + margin-top: 10px; } .paginator { - font: 12px sans-serif; - padding: 5px 0 10px; + font: 12px sans-serif; + padding: 5px 0 10px; +} + +.paginator .prev a, .paginator .prev a:visited, .paginator .next a, .paginator .next a:visited { + background-color: #FFFFFF; + border: 1px solid #FFFFFF; + color: #777777; + font: bold 100% sans-serif; + padding: 2px 4px 3px; } -.paginator .prev a,.paginator .prev a:visited,.paginator .next a,.paginator .next a:visited { - background-color: #FFFFFF; - border: 1px solid #FFFFFF; - color: #777777; - font: bold 100% sans-serif; - padding: 2px 4px 3px; +.paginator .prev { + margin-right: 0.5em; } -.paginator .prev { margin-right: 0.5em; } -.paginator .next { margin-left: 0.5em; } +.paginator .next { + margin-left: 0.5em; +} -.paginator .page a,.paginator .page a:visited,.paginator .curr { - background-color: #FFFFFF; - border: 1px solid #CCCCCC; - color: #777777; - font: 0.875em verdana; - margin: 0 0.25em; - padding: 0.25em; +.paginator .page a, .paginator .page a:visited, .paginator .curr { + background-color: #FFFFFF; + border: 1px solid #CCCCCC; + color: #777777; + font: 0.875em verdana; + margin: 0 0.25em; + padding: 0.25em; } .paginator .curr { - background-color: #777777; - border: 1px solid #777777; - color: #FFFFFF; - font-weight: bold; + background-color: #777777; + border: 1px solid #777777; + color: #FFFFFF; + font-weight: bold; } -.paginator .page a:hover,.paginator .prev a:hover,.paginator .next a:hover { - background-color: #777777; - border: 1px solid #777777; - color: #FFFFFF; - text-decoration: none; +.paginator .page a:hover, .paginator .prev a:hover, .paginator .next a:hover { + background-color: #777777; + border: 1px solid #777777; + color: #FFFFFF; + text-decoration: none; } .paginator .text { - color: #777777; - font: bold 100% sans-serif; - padding: 0.3em; + color: #777777; + font: bold 100% sans-serif; + padding: 0.3em; } -.paginator-container-left { padding: 5px 0 10px; } +.paginator-container-left { + padding: 5px 0 10px; +} .tags { - display: block; - font-family: sans-serif; - line-height: 200%; - margin-top: 5px; + display: block; + font-family: sans-serif; + line-height: 200%; + margin-top: 5px; } -.tags a,span.tag { - background-color: #EEEEEE; - border-bottom: 1px solid #CCCCCC; - border-right: 1px solid #CCCCCC; - color: #777777; - font-size: 11px; - font-weight: normal; - padding: 1px 8px; - text-decoration: none; - white-space: nowrap; +.tags a, span.tag { + background-color: #EEEEEE; + border-bottom: 1px solid #CCCCCC; + border-right: 1px solid #CCCCCC; + color: #777777; + font-size: 11px; + font-weight: normal; + padding: 1px 8px; + text-decoration: none; + white-space: nowrap; } .tags a:hover { - background-color: #356FCB; - color: #FFFFFF; + background-color: #356FCB; + color: #FFFFFF; } .tag-number { - font-family: sans-serif; - font-weight: 700; + font-family: sans-serif; + font-weight: 700; } .marked-tags { - margin-bottom: 5px; - margin-top: 0; + margin-bottom: 5px; + margin-top: 0; } a.medal { - background: none repeat scroll 0 0 #FFFFCD; - border-color: #EEEEEE #CCCCCC #CCCCCC #EEEEEE; - border-left: 1px solid #EEEEEE; - border-style: solid; - border-width: 1px; - color: #333333; - font-size: 14px; - font-weight: bold; - line-height: 250%; - padding: 4px 12px 4px 6px; - text-decoration: none; + background: none repeat scroll 0 0 #FFFFCD; + border-color: #EEEEEE #CCCCCC #CCCCCC #EEEEEE; + border-left: 1px solid #EEEEEE; + border-style: solid; + border-width: 1px; + color: #333333; + font-size: 14px; + font-weight: bold; + line-height: 250%; + padding: 4px 12px 4px 6px; + text-decoration: none; } a.medal:hover { - background: url("../images/medala_on.gif") no-repeat scroll 0 0 transparent; - border-color: #E7E296 #D1CA3D #D1CA3D #E7E296; - border-left: 1px solid #E7E296; - border-style: solid; - border-width: 1px; - color: #333333; - text-decoration: none; + background: url("../images/medala_on.gif") no-repeat scroll 0 0 transparent; + border-color: #E7E296 #D1CA3D #D1CA3D #E7E296; + border-left: 1px solid #E7E296; + border-style: solid; + border-width: 1px; + color: #333333; + text-decoration: none; } .tabBar { - background-color: #FFFFFF; - border-bottom: 1px solid white; - clear: both; - height: 30px; - margin-bottom: 3px; - width: 100%; + background-color: #FFFFFF; + border-bottom: 1px solid white; + clear: both; + height: 30px; + margin-bottom: 3px; + width: 100%; } .tabsA { - background-color: #FFFFFF; - display: block; - float: right; - font-weight: bold; - height: 20px; - position: relative; + background-color: #FFFFFF; + display: block; + float: right; + font-weight: bold; + height: 20px; + position: relative; } .tabsA a { - background: none repeat scroll 0 0 #EEEEEE; - border-bottom: 1px solid #CCCCCC; - border-right: 1px solid #CCCCCC; - color: #888A85; - display: block; - float: left; - height: 20px; - line-height: 22px; - margin: 5px 4px 0 0; - padding: 0 11px; - text-decoration: none; + background: none repeat scroll 0 0 #EEEEEE; + border-bottom: 1px solid #CCCCCC; + border-right: 1px solid #CCCCCC; + color: #888A85; + display: block; + float: left; + height: 20px; + line-height: 22px; + margin: 5px 4px 0 0; + padding: 0 11px; + text-decoration: none; } -.tabsA a.on,.tabsA a:hover { - background: none repeat scroll 0 0 #FFFFFF; - color: #A40000; +.tabsA a.on, .tabsA a:hover { + background: none repeat scroll 0 0 #FFFFFF; + color: #A40000; } .tabsA a:hover { - background: none repeat scroll 0 0 #356FCB; - color: #FFFFFF; + background: none repeat scroll 0 0 #356FCB; + color: #FFFFFF; } .headlineA { - border-bottom: 1px solid #777777; - font-size: 13px; - font-weight: 800; - height: 30px; - margin-bottom: 12px; - padding-bottom: 2px; - text-align: right; + border-bottom: 1px solid #777777; + font-size: 13px; + font-weight: 800; + height: 30px; + margin-bottom: 12px; + padding-bottom: 2px; + text-align: right; } .headQuestions { - background: url("../images/dot-list.gif") no-repeat scroll left center transparent; - border-bottom: 0 solid #777777; - float: left; - font-size: 15px; - font-weight: 700; - height: 23px; - line-height: 23px; - margin: 5px 0 0 5px; - padding: 0 6px 0 15px; + background: url("../images/dot-list.gif") no-repeat scroll left center transparent; + border-bottom: 0 solid #777777; + float: left; + font-size: 15px; + font-weight: 700; + height: 23px; + line-height: 23px; + margin: 5px 0 0 5px; + padding: 0 6px 0 15px; } .headUsers { - background: url("../images/dot-list.gif") no-repeat scroll left center transparent; - border-bottom: 0 solid #777777; - float: left; - font-size: 15px; - font-weight: 700; - height: 23px; - line-height: 23px; - margin: 5px 0 0 5px; - padding: 0 6px 0 15px; + background: url("../images/dot-list.gif") no-repeat scroll left center transparent; + border-bottom: 0 solid #777777; + float: left; + font-size: 15px; + font-weight: 700; + height: 23px; + line-height: 23px; + margin: 5px 0 0 5px; + padding: 0 6px 0 15px; } .headMedals { - background: url("../images/dot-list.gif") no-repeat scroll left center transparent; - border-bottom: 0 solid #777777; - float: left; - font-size: 15px; - font-weight: 700; - height: 23px; - line-height: 23px; - margin: 5px 0 0 5px; - padding: 0 6px 0 15px; + background: url("../images/dot-list.gif") no-repeat scroll left center transparent; + border-bottom: 0 solid #777777; + float: left; + font-size: 15px; + font-weight: 700; + height: 23px; + line-height: 23px; + margin: 5px 0 0 5px; + padding: 0 6px 0 15px; } .headNormal { - border-bottom: 1px solid #777777; - font-size: 15px; - font-weight: bold; - margin-bottom: 12px; - padding: 3px; - text-align: left; + border-bottom: 1px solid #777777; + font-size: 15px; + font-weight: bold; + margin-bottom: 12px; + padding: 3px; + text-align: left; } .headUser { - border-bottom: 1px solid #777777; - font-size: 20px; - font-weight: 800; - margin-bottom: 12px; - padding: 5px; - text-align: left; + border-bottom: 1px solid #777777; + font-size: 20px; + font-weight: 800; + margin-bottom: 12px; + padding: 5px; + text-align: left; } .questions-related { - font-weight: 700; - word-wrap: break-word; + font-weight: 700; + word-wrap: break-word; } .questions-related p { - font-size: 100%; - line-height: 20px; - margin-bottom: 10px; + font-size: 100%; + line-height: 20px; + margin-bottom: 10px; } .question-body { - font-size: 13px; - line-height: 20px; - min-height: 100px; + font-size: 13px; + line-height: 20px; + min-height: 100px; } -.question-body img { max-width: 640px; } +.question-body img { + max-width: 640px; +} .vote-buttons { - float: left; - text-align: center; + float: left; + text-align: center; } span.form-error { - color: #990000; - font-weight: normal; - margin-left: 5px; + color: #990000; + font-weight: normal; + margin-left: 5px; } ul.errorlist li { - color: #990000; - font-weight: normal; - margin-left: 0px; + color: #990000; + font-weight: normal; + margin-left: 0px; margin-top: 5px; } .answer { - border-bottom: 1px solid #CCCCCE; - padding-top: 10px; - width: 100%; + border-bottom: 1px solid #CCCCCE; + padding-top: 10px; + width: 100%; } .answer-body { - font-size: 13px; - line-height: 20px; - min-height: 80px; + font-size: 13px; + line-height: 20px; + min-height: 80px; } -.answer-body img { max-width: 640px; } +.answer-body img { + max-width: 640px; +} -.answered-by-owner { background: none repeat scroll 0 0 #E9E9FF; } +.answered-by-owner { + background: none repeat scroll 0 0 #E9E9FF; +} .accepted-answer { - background-color: #EBFFE6; - border-bottom-color: #9BD59B; + background-color: #EBFFE6; + border-bottom-color: #9BD59B; } .answered { - background: none repeat scroll 0 0 #E5EBF8; - color: #314362; + background: none repeat scroll 0 0 #E5EBF8; + color: #314362; } -.answered-accepted,.answer-votes.answered-accepted { - background: none repeat scroll 0 0 #E6F8DD; - color: #3A6231; +.answered-accepted, .answer-votes.answered-accepted { + background: none repeat scroll 0 0 #E6F8DD; + color: #3A6231; } .unanswered { - background: none repeat scroll 0 0 #F3E3E1; - color: #6B2B28; + background: none repeat scroll 0 0 #F3E3E1; + color: #6B2B28; } .tagsList { - list-style-type: none; - margin: 0; - min-height: 360px; - padding: 0; + list-style-type: none; + margin: 0; + min-height: 360px; + padding: 0; } .tagsList li { - float: left; - width: 235px; + float: left; + width: 235px; } .badge-list { - list-style-type: none; - margin: 0; + list-style-type: none; + margin: 0; +} + +.badge-list a { + color: #3060A8; } -.badge-list a { color: #3060A8; } -.badge-list a.medal { color: #333333; } -.list-item { margin-left: 15px; } +.badge-list a.medal { + color: #333333; +} + +.list-item { + margin-left: 15px; +} .list-item li { - font-size: 13px; - line-height: 20px; - list-style-type: disc; - margin-bottom: 10px; + font-size: 13px; + line-height: 20px; + list-style-type: disc; + margin-bottom: 10px; +} + +.form-row { + line-height: 25px; } -.form-row { line-height: 25px; } -table.form-as-table { margin-top: 5px; } +table.form-as-table { + margin-top: 5px; +} table.form-as-table ul { - display: inline; - list-style-type: none; + display: inline; + list-style-type: none; +} + +table.form-as-table li { + display: inline; +} + +table.form-as-table pre { + display: inline; } -table.form-as-table li { display: inline; } -table.form-as-table pre { display: inline; } -table.check-table td { padding-right: 50px; } +table.check-table td { + padding-right: 50px; +} .submit-row { - clear: both; - display: block; - line-height: 30px; - padding-top: 10px; + clear: both; + display: block; + line-height: 30px; + padding-top: 10px; } .error { - color: darkred; - font-size: 10px; - margin: 0; + color: darkred; + font-size: 10px; + margin: 0; } .small { - font-size: 11px; + font-size: 11px; } span.form-error { - color: #990000; - font-size: 90%; - font-weight: normal; - margin-left: 5px; + color: #990000; + font-size: 90%; + font-weight: normal; + margin-left: 5px; } .title-desc { - color: #666666; - font-size: 90%; + color: #666666; + font-size: 90%; } #editor { - font-size: 100%; - line-height: 18px; - min-height: 200px; - width: 100%; + font-size: 100%; + line-height: 18px; + min-height: 200px; + width: 100%; } .wmd-preview { - background-color: #F5F5F5; - margin-top: 10px; - min-height: 20px; - padding: 6px; - width: 98%; + background-color: #F5F5F5; + margin-top: 10px; + min-height: 20px; + padding: 6px; + width: 98%; } .preview-toggle { - color: #AAAAAA; - font-weight: 600; - text-align: left; - width: 100%; + color: #AAAAAA; + font-weight: 600; + text-align: left; + width: 100%; } -.preview-toggle span:hover { cursor: pointer; } -#revisions { width: 950px; } +.preview-toggle span:hover { + cursor: pointer; +} + +#revisions { + width: 950px; +} .revision { - font-size: 13px; - margin: 10px 0; - width: 100%; + font-size: 13px; + margin: 10px 0; + width: 100%; } .revision .header { - background-color: #EEEEEE; - cursor: pointer; - padding: 5px; + background-color: #EEEEEE; + cursor: pointer; + padding: 5px; +} + +.revision .author { + background-color: #E9E9FF; } -.revision .author { background-color: #E9E9FF; } -.revision .summary { padding: 5px 0 10px; } +.revision .summary { + padding: 5px 0 10px; +} .revision .summary span { - background-color: yellow; - display: inline; - padding-left: 3px; - padding-right: 3px; + background-color: yellow; + display: inline; + padding-left: 3px; + padding-right: 3px; } .revision h1 { - font-size: 130%; - font-weight: 600; - padding: 15px 0; + font-size: 130%; + font-weight: 600; + padding: 15px 0; } .revision-mark { - display: inline-block; - font-size: 90%; - overflow: hidden; - text-align: left; - width: 200px; + display: inline-block; + font-size: 90%; + overflow: hidden; + text-align: left; + width: 200px; } .revision-number { - font-family: sans-serif; - font-size: 300%; - font-weight: bold; + font-family: sans-serif; + font-size: 300%; + font-weight: bold; } .revision .body { - margin-bottom: 50px; - padding-left: 10px; + margin-bottom: 50px; + padding-left: 10px; +} + +del { + color: #FF5F5F; } -del { color: #FF5F5F; } -ins { background-color: #97FF97; } +ins { + background-color: #97FF97; +} .count { - color: #777777; - font-family: Arial; - font-size: 200%; - font-weight: 700; + color: #777777; + font-family: Arial; + font-size: 200%; + font-weight: 700; } .scoreNumber { - color: #777777; - font-family: Arial; - font-size: 35px; - font-weight: 800; - line-height: 40px; + color: #777777; + font-family: Arial; + font-size: 35px; + font-weight: 800; + line-height: 40px; } -.user-details { font-size: 13px; } +.user-details { + font-size: 13px; +} .user-about { - background-color: #EEEEEE; - height: 200px; - line-height: 20px; - overflow: auto; - padding: 10px; - width: 90%; + background-color: #EEEEEE; + height: 200px; + line-height: 20px; + overflow: auto; + padding: 10px; + width: 90%; } .user-edit-link { - background: url("../images/edit.png") no-repeat scroll 0 0 transparent; - padding-left: 20px; + background: url("../images/edit.png") no-repeat scroll 0 0 transparent; + padding-left: 20px; +} + +.user-info-table { + margin-bottom: 10px; } -.user-info-table { margin-bottom: 10px; } -.relativetime { text-decoration: none; } +.relativetime { + text-decoration: none; +} .answer-summary { - clear: both; - display: block; - padding: 3px; + clear: both; + display: block; + padding: 3px; } .answer-votes { - background-color: #EEEEEE; - color: #555555; - float: left; - font-family: Arial; - font-size: 110%; - font-weight: bold; - height: 15px; - margin-right: 10px; - padding: 4px 4px 5px; - text-align: center; - text-decoration: none; - width: 20px; + background-color: #EEEEEE; + color: #555555; + float: left; + font-family: Arial; + font-size: 110%; + font-weight: bold; + height: 15px; + margin-right: 10px; + padding: 4px 4px 5px; + text-align: center; + text-decoration: none; + width: 20px; } .vote-count { - color: #777777; - font-family: Arial; - font-size: 160%; - font-weight: 700; + color: #777777; + font-family: Arial; + font-size: 160%; + font-weight: 700; } .user-action-1 { - color: #333333; - font-weight: bold; + color: #333333; + font-weight: bold; } .user-action-2 { - color: #CCCCCC; - font-weight: bold; + color: #CCCCCC; + font-weight: bold; } -.user-action-3 { color: #333333; } -.user-action-4 { color: #333333; } -.user-action-7 { color: #333333; } +.user-action-3 { + color: #333333; +} + +.user-action-4 { + color: #333333; +} + +.user-action-7 { + color: #333333; +} .user-action-8 { - background-color: #CCCCCC; - color: #763333; - font-weight: bold; - padding: 3px; + background-color: #CCCCCC; + color: #763333; + font-weight: bold; + padding: 3px; } .question-title-link a { - color: #0077CC; - font-weight: bold; + color: #0077CC; + font-weight: bold; +} + +.answer-title-link a { + color: #333333; +} + +.post-type-1 a { + font-weight: bold; +} + +.post-type-3 a { + font-weight: bold; } -.answer-title-link a { color: #333333; } -.post-type-1 a { font-weight: bold; } -.post-type-3 a { font-weight: bold; } -.post-type-2 a { color: #333333; } -.post-type-4 a { color: #333333; } -.post-type-8 a { color: #333333; } -.badge1 { color: #FFCC00; } -.silver,.badge2 { color: #CCCCCC; } -.bronze,.badge3 { color: #CC9933; } +.post-type-2 a { + color: #333333; +} + +.post-type-4 a { + color: #333333; +} + +.post-type-8 a { + color: #333333; +} + +.badge1 { + color: #FFCC00; +} + +.silver, .badge2 { + color: #CCCCCC; +} + +.bronze, .badge3 { + color: #CC9933; +} .score { - color: #333333; - font-size: 110%; - font-weight: bold; - margin-left: 3px; + color: #333333; + font-size: 110%; + font-weight: bold; + margin-left: 3px; } .footerLinks { - color: #3060A8; - font-size: 13px; + color: #3060A8; + font-size: 13px; } .footerLinks a { - color: #3060A8; - font-size: 13px; + color: #3060A8; + font-size: 13px; } .user { - line-height: 140%; - padding: 5px; - width: 170px; + line-height: 140%; + padding: 5px; + width: 170px; } .user ul { - list-style-type: none; - margin: 0; + list-style-type: none; + margin: 0; } .user .thumb { - clear: both; - display: inline; - float: left; - margin-right: 4px; + clear: both; + display: inline; + float: left; + margin-right: 4px; } .message { - background-color: #EEEEEE; - border: 1px solid #AAAAAA; - margin: 10px 0; - padding: 5px; + background-color: #EEEEEE; + border: 1px solid #AAAAAA; + margin: 10px 0; + padding: 5px; +} + +.message p { + margin-bottom: 0; } -.message p { margin-bottom: 0; } -.darkred { color: darkred; } +.darkred { + color: darkred; +} .submit { - background-color: #D4D0C8; - border: 1px solid #777777; - cursor: pointer; - font-size: 120%; - font-weight: bold; - height: 40px; - padding-bottom: 4px; + background-color: #D4D0C8; + border: 1px solid #777777; + cursor: pointer; + font-size: 120%; + font-weight: bold; + height: 40px; + padding-bottom: 4px; } -.submit:hover { text-decoration: underline; } -.ask-body { padding-right: 10px; } +.submit:hover { + text-decoration: underline; +} + +.ask-body { + padding-right: 10px; +} .notify { - background-color: #F4A83D; - color: #444444; - font-weight: bold; - left: 0; - padding: 0; - position: fixed; - text-align: center; - top: 0; - width: 100%; - z-index: 100; + background-color: #F4A83D; + color: #444444; + font-weight: bold; + left: 0; + padding: 0; + position: fixed; + text-align: center; + top: 0; + width: 100%; + z-index: 100; } .notify p { - font-size: 16px; - margin-bottom: 5px; - margin-top: 5px; + font-size: 16px; + margin-bottom: 5px; + margin-top: 5px; } #close-notify { - background-color: #FAD163; - border: 2px solid #735005; - color: #735005; - cursor: pointer; - font-size: 14px; - line-height: 18px; - padding: 0 3px; - position: absolute; - right: 5px; - text-decoration: none; - top: 5px; -} - -#close-notify:hover { text-decoration: none; } -.big { font-size: 15px; } -.strong { font-weight: bold; } + background-color: #FAD163; + border: 2px solid #735005; + color: #735005; + cursor: pointer; + font-size: 14px; + line-height: 18px; + padding: 0 3px; + position: absolute; + right: 5px; + text-decoration: none; + top: 5px; +} + +#close-notify:hover { + text-decoration: none; +} + +.big { + font-size: 15px; +} + +.strong { + font-weight: bold; +} .orange { - color: #D64000; - font-weight: bold; + color: #D64000; + font-weight: bold; } -.grey { color: #808080; } +.grey { + color: #808080; +} .about div { - border-top: 1px dashed #AAAAAA; - padding: 10px 5px; + border-top: 1px dashed #AAAAAA; + padding: 10px 5px; } .about div.first { - border-top: medium none; - padding-top: 0; + border-top: medium none; + padding-top: 0; } -.about p { margin-bottom: 10px; } +.about p { + margin-bottom: 10px; +} .about a { - color: #D64000; - text-decoration: underline; + color: #D64000; + text-decoration: underline; } .about h3 { - font-size: 15px; - font-weight: 700; - line-height: 30px; - padding-top: 0; + font-size: 15px; + font-weight: 700; + line-height: 30px; + padding-top: 0; } -.nomargin { margin: 0; } -.inline-block { display: inline-block; } -.list-table td { vertical-align: top; } +.nomargin { + margin: 0; +} + +.inline-block { + display: inline-block; +} + +.list-table td { + vertical-align: top; +} table.form-as-table input { - display: inline; - margin-left: 4px; + display: inline; + margin-left: 4px; } ul.form-horizontal-rows { - list-style: none outside none; - margin: 0; + list-style: none outside none; + margin: 0; } ul.form-horizontal-rows li { - height: 40px; - position: relative; + height: 40px; + position: relative; } -ul.form-horizontal-rows label { display: inline-block; } +ul.form-horizontal-rows label { + display: inline-block; +} ul.form-horizontal-rows label { - bottom: 6px; - font-size: 12px; - left: 0; - line-height: 12px; - margin: 0; - position: absolute; + bottom: 6px; + font-size: 12px; + left: 0; + line-height: 12px; + margin: 0; + position: absolute; } ul.form-horizontal-rows li input { - bottom: 0; - left: 180px; - margin: 0; - position: absolute; + bottom: 0; + left: 180px; + margin: 0; + position: absolute; } -#changepw-form li input { left: 150px; } +#changepw-form li input { + left: 150px; +} .user-profile-tool-links { - font-weight: bold; - padding-bottom: 10px; + font-weight: bold; + padding-bottom: 10px; } .post-controls, .tags-container { - font-size: 11px; - line-height: 12px; - margin-bottom: 5px; - min-width: 200px; + font-size: 11px; + line-height: 12px; + margin-bottom: 5px; + min-width: 200px; } .tags-container { - margin: 0 0 16px 0; + margin: 0 0 16px 0; } .post-controls { float: left; } -#question-controls .tags { margin: 0 0 3px; } +#question-controls .tags { + margin: 0 0 3px; +} .post-update-info { - display: inline-block; - float: right; - margin-bottom: 5px; - width: 190px; + display: inline-block; + float: right; + margin-bottom: 5px; + width: 190px; } .post-update-info p { - font-size: 11px; - line-height: 15px; - margin: 0 0 4px; - padding: 0; + font-size: 11px; + line-height: 15px; + margin: 0 0 4px; + padding: 0; } .post-update-info img { - float: left; - margin: 4px 8px 0 0; - width: 32px; + float: left; + margin: 4px 8px 0 0; + width: 32px; +} + +#tagSelector { + padding-bottom: 2px; +} + +#hideIgnoredTagsControl { + margin: 5px 0 0; } -#tagSelector { padding-bottom: 2px; } -#hideIgnoredTagsControl { margin: 5px 0 0; } -#hideIgnoredTagsCb { margin: 0 2px 0 1px; } +#hideIgnoredTagsCb { + margin: 0 2px 0 1px; +} a.sidebar_button { - background: none repeat scroll 0 0 #EEEEEE; - color: black; - cursor: pointer; - font-size: 11px; - padding: 3px; + background: none repeat scroll 0 0 #EEEEEE; + color: black; + cursor: pointer; + font-size: 11px; + padding: 3px; } a.sidebar_button:hover { - background-color: #777777; - color: white; - text-decoration: none; + background-color: #777777; + color: white; + text-decoration: none; } -a.post-vote,.favorite-mark,a.accept-answer { - display: block; - height: 24px; - position: relative; - width: 24px; +a.post-vote, .favorite-mark, a.accept-answer { + display: block; + height: 24px; + position: relative; + width: 24px; } -a.post-vote.up { background: url("../images/vote-arrow-up.png") no-repeat scroll center center transparent; } -a.post-vote.up.on,a.post-vote.up:hover { background: url("../images/vote-arrow-up-on.png") no-repeat scroll center center transparent; } -a.post-vote.down { background: url("../images/vote-arrow-down.png") no-repeat scroll center center transparent; } -a.post-vote.down.on,a.post-vote.down:hover { background: url("../images/vote-arrow-down-on.png") no-repeat scroll center center transparent; } -a.accept-answer { background: url("../images/vote-accepted.png") no-repeat scroll center center transparent; } -a.accept-answer.on,a.accept-answer:hover { background: url("../images/vote-accepted-on.png") no-repeat scroll center center transparent; } +a.post-vote.up { + background: url("../images/vote-arrow-up.png") no-repeat scroll center center transparent; +} + +a.post-vote.up.on, a.post-vote.up:hover { + background: url("../images/vote-arrow-up-on.png") no-repeat scroll center center transparent; +} + +a.post-vote.down { + background: url("../images/vote-arrow-down.png") no-repeat scroll center center transparent; +} + +a.post-vote.down.on, a.post-vote.down:hover { + background: url("../images/vote-arrow-down-on.png") no-repeat scroll center center transparent; +} + +a.accept-answer { + background: url("../images/vote-accepted.png") no-repeat scroll center center transparent; +} + +a.accept-answer.on, a.accept-answer:hover { + background: url("../images/vote-accepted-on.png") no-repeat scroll center center transparent; +} .community-wiki { font-size: 11px; @@ -1182,55 +1375,73 @@ a.accept-answer.on,a.accept-answer:hover { background: url("../images/vote-accep } .post-score, .comments-char-left-count { - color: #777777; - font-family: Arial; - font-size: 165%; - font-weight: bold; - padding: 0 0 3px; + color: #777777; + font-family: Arial; + font-size: 165%; + font-weight: bold; + padding: 0 0 3px; +} + +.favorite-mark { + background: url("../images/vote-favorite-off.png") no-repeat scroll center center transparent; } -.favorite-mark { background: url("../images/vote-favorite-off.png") no-repeat scroll center center transparent; } -.favorite-mark.on,a.favorite-mark:hover { background: url("../images/vote-favorite-on.png") no-repeat scroll center center transparent; } +.favorite-mark.on, a.favorite-mark:hover { + background: url("../images/vote-favorite-on.png") no-repeat scroll center center transparent; +} .favorite-count { - color: #777777; - font-family: Arial; - font-size: 100%; - font-weight: bold; - padding: 0; + color: #777777; + font-family: Arial; + font-size: 100%; + font-weight: bold; + padding: 0; } -.comments-container { clear: both; } -.comments-container { padding: 0; } -.answered-by-owner .comments-container { background-color: #E6ECFF; } -.accepted-answer .comments-container { background-color: #CCFFBF; } +.comments-container { + clear: both; +} + +.comments-container { + padding: 0; +} + +.answered-by-owner .comments-container { + background-color: #E6ECFF; +} + +.accepted-answer .comments-container { + background-color: #CCFFBF; +} .comment { - border-top: 1px dotted #CCCCCE; - margin: 0; + border-top: 1px dotted #CCCCCE; + margin: 0; position: relative; } -.comment.not_top_scorer { display: none; } +.comment.not_top_scorer { + display: none; +} .comment-score { - color: #777777; - font-family: Arial; - font-size: 16px; - font-weight: bold; - padding-top: 3px; - vertical-align: top; + color: #777777; + font-family: Arial; + font-size: 16px; + font-weight: bold; + padding-top: 3px; + vertical-align: top; float: left; - width: 22px; + width: 22px; height: 100%; text-align: center; } .comment-text { - color: #444444; - font-size: 12px; - margin: 0 0 0 22px; - padding: 0; + color: #444444; + font-size: 12px; + margin: 0 0 0 22px; + padding: 0; } .comment-text p { @@ -1238,8 +1449,8 @@ a.accept-answer.on,a.accept-answer:hover { background: url("../images/vote-accep } .comment-info { - font-size: 11px; - margin: 0 0 4px 0; + font-size: 11px; + margin: 0 0 4px 0; text-align: right; height: 18px; vertical-align: middle; @@ -1247,69 +1458,88 @@ a.accept-answer.on,a.accept-answer:hover { background: url("../images/vote-accep .comment-info * { float: right; - height: 18px; - margin-left: 4px; + height: 18px; + margin-left: 4px; +} + +a.comment-like, a.comment-delete, a.comment-edit { + margin-left: 2px; + width: 18px; } -a.comment-like,a.comment-delete,a.comment-edit { - margin-left: 2px; - width: 18px; +a.comment-like { + background: url("../images/comment-like.png") no-repeat scroll center center transparent; } -a.comment-like { background: url("../images/comment-like.png") no-repeat scroll center center transparent; } -a.comment-like:hover,a.comment-like.on { background: url("../images/comment-like-on.png") no-repeat scroll center center transparent; } -a.comment-delete { background: url("../images/comment-delete.png") no-repeat scroll center center transparent; } -a.comment-delete:hover { background: url("../images/comment-delete-hover.png") no-repeat scroll center center transparent; } -a.comment-edit { background: url("../images/comment-edit.png") no-repeat scroll center center transparent; } -a.comment-edit:hover { background: url("../images/comment-edit-hover.png") no-repeat scroll center center transparent; } +a.comment-like:hover, a.comment-like.on { + background: url("../images/comment-like-on.png") no-repeat scroll center center transparent; +} + +a.comment-delete { + background: url("../images/comment-delete.png") no-repeat scroll center center transparent; +} + +a.comment-delete:hover { + background: url("../images/comment-delete-hover.png") no-repeat scroll center center transparent; +} + +a.comment-edit { + background: url("../images/comment-edit.png") no-repeat scroll center center transparent; +} + +a.comment-edit:hover { + background: url("../images/comment-edit-hover.png") no-repeat scroll center center transparent; +} .comment-form-container { - display: none; - padding-top: 12px; + display: none; + padding-top: 12px; } -.comment-form-widgets-container input { vertical-align: top; } +.comment-form-widgets-container input { + vertical-align: top; +} .comment-form-widgets-container textarea { - height: 80px; - width: 80%; + height: 80px; + width: 80%; float: left; } span.comment-chars-left { - font-size: 11px; - margin-right: 20px; + font-size: 11px; + margin-right: 20px; } div.comment-tools { - border-top: 1px dotted #CCCCCE; - padding-top: 12px; - text-align: right; + border-top: 1px dotted #CCCCCE; + padding-top: 12px; + text-align: right; } div.comment-tools .comments-showing { - color: #777777; - font-size: 11px; + color: #777777; + font-size: 11px; } div.comment-tools a { - background: none repeat scroll 0 0 #EEEEEE; - color: black; - cursor: pointer; - font-size: 11px; - padding: 3px; + background: none repeat scroll 0 0 #EEEEEE; + color: black; + cursor: pointer; + font-size: 11px; + padding: 3px; } div.comment-tools a:hover { - background-color: #777777; - color: white; - text-decoration: none; + background-color: #777777; + color: white; + text-decoration: none; } .action-link { - color: #777777; - cursor: pointer; - padding: 3px; + color: #777777; + cursor: pointer; + padding: 3px; } .action-link a { @@ -1317,14 +1547,18 @@ div.comment-tools a:hover { } .action-link a.ajax-command:hover { - background-color: #777777; - color: #FFFFFF; - text-decoration: none; + background-color: #777777; + color: #FFFFFF; + text-decoration: none; } -.action-link-separator { color: #CCCCCC; } +.action-link-separator { + color: #CCCCCC; +} -.deleted {background-color: #F4E7E7;} +.deleted { + background-color: #F4E7E7; +} #command-loader { position: fixed; @@ -1360,7 +1594,7 @@ div.comment-tools a:hover { } .comments-char-left-count.warn { - color: orange; + color: orange; } #ask-related-questions { @@ -1391,7 +1625,7 @@ div.dialog, .context-menu-dropdown { .context-menu-dropdown li.item { padding: 4px 8px 4px 8px; - -moz-border-radius: 5px; + -moz-border-radius: 5px; -webkit-border-radius: 5px; } @@ -1471,4 +1705,8 @@ div.dialog.prompt .dialog-content select, div.dialog.prompt .dialog-content text .user-prompt .prompt-buttons { text-align: right; +} + +.suspended-user { + text-decoration: line-through; } \ No newline at end of file diff --git a/forum/skins/default/templates/403.html b/forum/skins/default/templates/403.html new file mode 100644 index 0000000..583e550 --- /dev/null +++ b/forum/skins/default/templates/403.html @@ -0,0 +1,47 @@ +{% extends "base_content.html" %} +{% load i18n %} +{% block title %}{% trans "Forbidden" %}{% endblock %} +{% block forestyle%} + +{% endblock %} +{% block forejs %} + +{% endblock %} +{% block content %} +
+ {% trans "Forbidden" %} +
+
+
+

{% trans "Sorry, could not find the page you requested." %}

+
+ {% trans "This might have happened for the following reasons:" %}
+
    +
  • {% trans "this question or answer has been deleted;" %}
  • +
  • {% trans "url has error - please check it;" %}
  • +
  • {% trans "the page you tried to visit is protected or you don't have sufficient points, see" %} faq;
  • +
  • {% trans "if you believe this error 404 should not have occured, please" %} + {% trans "report this problem" %}
  • +
+
+ + + +
+ +
+{% endblock %} diff --git a/forum/skins/default/templates/404.html b/forum/skins/default/templates/404.html index d02a421..067e5ab 100644 --- a/forum/skins/default/templates/404.html +++ b/forum/skins/default/templates/404.html @@ -1,7 +1,7 @@ {% extends "base_content.html" %} {% load i18n %} -{% block title %}{% spaceless %}404 Error{% endspaceless %}{% endblock %} +{% block title %}{% trans "404 Error" %}{% endblock %} {% block forestyle%}