Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser.py	(revision 11254)
@@ -39,6 +39,4 @@
 from waeup.kofa.browser.breadcrumbs import Breadcrumb
 from waeup.kofa.browser.pages import ContactAdminForm, ExportCSVView, doll_up
-from waeup.kofa.browser.resources import (
-    datepicker, datatable, tabs, warning, toggleall)
 from waeup.kofa.browser.layout import jsaction, action, UtilityView
 from waeup.kofa.browser.interfaces import ICaptchaManager
@@ -107,5 +105,5 @@
     """Flash a lock message.
     """
-    view.flash(_('The requested form is locked (read-only).'))
+    view.flash(_('The requested form is locked (read-only).'), type="warning")
     view.redirect(view.url(view.context))
     return
@@ -122,4 +120,5 @@
         value._p_activate()
         value_dict = dict([i for i in value.__dict__.items()])
+        value_dict['url'] = view.url(value)
         value_dict['removable_by_student'] = value.removable_by_student
         value_dict['mandatory'] = translate(str(value.mandatory), 'zope',
@@ -155,10 +154,10 @@
         view.flash(_(
             'Total credits exceed ${a}.',
-            mapping = {'a': max_credits}))
+            mapping = {'a': max_credits}), type="warning")
         return False
     try:
         view.context.addCourseTicket(ticket, course)
     except KeyError:
-        view.flash(_('The ticket exists.'))
+        view.flash(_('The ticket exists.'), type="warning")
         return False
     view.flash(_('Successfully added ${a}.',
@@ -258,10 +257,9 @@
     grok.require('waeup.viewStudentsContainer')
     grok.template('containerpage')
-    label = _('Student Section')
+    label = _('Find students')
     search_button = _('Find student(s)')
     pnav = 4
 
     def update(self, *args, **kw):
-        datatable.need()
         form = self.request.form
         self.hitlist = []
@@ -280,5 +278,5 @@
         else:
             if 'search' in form:
-                self.flash(_('Empty search string'))
+                self.flash(_('Empty search string'), type="warning")
             return
         if self.searchtype == 'current_session':
@@ -286,10 +284,11 @@
                 self.searchterm = int(self.searchterm)
             except ValueError:
-                self.flash(_('Only year dates allowed (e.g. 2011).'))
+                self.flash(_('Only year dates allowed (e.g. 2011).'),
+                           type="danger")
                 return
         self.hitlist = search(query=self.searchterm,
             searchtype=self.searchtype, view=self)
         if not self.hitlist:
-            self.flash(_('No student found.'))
+            self.flash(_('No student found.'), type="warning")
         return
 
@@ -307,7 +306,4 @@
 
     def update(self, *args, **kw):
-        datatable.need()
-        toggleall.need()
-        warning.need()
         form = self.request.form
         self.hitlist = []
@@ -323,5 +319,5 @@
         else:
             if 'search' in form:
-                self.flash(_('Empty search string'))
+                self.flash(_('Empty search string'), type="warning")
             return
         if self.searchtype == 'current_session':
@@ -329,5 +325,6 @@
                 self.searchterm = int(self.searchterm)
             except ValueError:
-                self.flash('Only year dates allowed (e.g. 2011).')
+                self.flash(_('Only year dates allowed (e.g. 2011).'),
+                           type="danger")
                 return
         if not 'entries' in form:
@@ -335,7 +332,7 @@
                 searchtype=self.searchtype, view=self)
             if not self.hitlist:
-                self.flash(_('No student found.'))
+                self.flash(_('No student found.'), type="warning")
             if 'remove' in form:
-                self.flash(_('No item selected.'))
+                self.flash(_('No item selected.'), type="warning")
             return
         entries = form['entries']
@@ -495,5 +492,5 @@
             self.flash(_('Your message has been sent.'))
         else:
-            self.flash(_('An smtp server error occurred.'))
+            self.flash(_('An smtp server error occurred.'), type="danger")
         return
 
@@ -535,11 +532,4 @@
 
     def update(self):
-        datepicker.need() # Enable jQuery datepicker in date fields.
-        tabs.need()
-        self.tab1 = self.tab2 = ''
-        qs = self.request.get('QUERY_STRING', '')
-        if not qs:
-            qs = 'tab1'
-        setattr(self, qs, 'active')
         super(StudentBaseManageFormPage, self).update()
         self.wf_info = IWorkflowInfo(self.context)
@@ -555,5 +545,5 @@
             errors = validator.validate_password(password, password_ctl)
             if errors:
-                self.flash( ' '.join(errors))
+                self.flash( ' '.join(errors), type="danger")
                 return
         changed_fields = self.applyData(self.context, **data)
@@ -764,14 +754,4 @@
         return form_fields
 
-    def update(self):
-        datepicker.need() # Enable jQuery datepicker in date fields.
-        tabs.need()
-        self.tab1 = self.tab2 = ''
-        qs = self.request.get('QUERY_STRING', '')
-        if not qs:
-            qs = 'tab1'
-        setattr(self, qs, 'active')
-        return super(StudentClearanceManageFormPage, self).update()
-
     @action(_('Save'), style='primary')
     def save(self, **data):
@@ -795,5 +775,5 @@
             self.flash(_('Student has been cleared.'))
         else:
-            self.flash(_('Student is in wrong state.'))
+            self.flash(_('Student is in wrong state.'), type="warning")
         self.redirect(self.url(self.context,'view_clearance'))
         return
@@ -814,5 +794,5 @@
     def update(self):
         if clearance_disabled_message(self.context):
-            self.flash(clearance_disabled_message(self.context))
+            self.flash(clearance_disabled_message(self.context), type="warning")
             self.redirect(self.url(self.context,'view_clearance'))
             return
@@ -824,11 +804,11 @@
             IWorkflowInfo(self.context).fireTransition('reset4')
             message = _('Clearance has been annulled.')
-            self.flash(message)
+            self.flash(message, type="warning")
         elif self.context.state == REQUESTED:
             IWorkflowInfo(self.context).fireTransition('reset3')
             message = _('Clearance request has been rejected.')
-            self.flash(message)
-        else:
-            self.flash(_('Student is in wrong state.'))
+            self.flash(message, type="warning")
+        else:
+            self.flash(_('Student is in wrong state.'), type="warning")
             self.redirect(self.url(self.context,'view_clearance'))
             return
@@ -987,12 +967,4 @@
             return
         super(StudyCourseManageFormPage, self).update()
-        tabs.need()
-        self.tab1 = self.tab2 = ''
-        qs = self.request.get('QUERY_STRING', '')
-        if not qs:
-            qs = 'tab1'
-        setattr(self, qs, 'active')
-        warning.need()
-        datatable.need()
         return
 
@@ -1003,5 +975,6 @@
         except ConstraintNotSatisfied:
             # The selected level might not exist in certificate
-            self.flash(_('Current level not available for certificate.'))
+            self.flash(_('Current level not available for certificate.'),
+                       type="warning")
             return
         notify(grok.ObjectModifiedEvent(self.context.__parent__))
@@ -1023,11 +996,12 @@
             yield(dict(code=code, title=title))
 
-    @action(_('Add study level'))
+    @action(_('Add study level'), style='primary')
     def addStudyLevel(self, **data):
         level_code = self.request.form.get('addlevel', None)
         level_session = self.request.form.get('level_session', None)
         if not level_session:
-            self.flash(_('You must select a session for the level.'))
-            self.redirect(self.url(self.context, u'@@manage')+'?tab2')
+            self.flash(_('You must select a session for the level.'),
+                       type="warning")
+            self.redirect(self.url(self.context, u'@@manage')+'#tab2')
             return
         studylevel = createObject(u'waeup.StudentStudyLevel')
@@ -1039,6 +1013,6 @@
             self.flash(_('Study level has been added.'))
         except KeyError:
-            self.flash(_('This level exists.'))
-        self.redirect(self.url(self.context, u'@@manage')+'?tab2')
+            self.flash(_('This level exists.'), type="warning")
+        self.redirect(self.url(self.context, u'@@manage')+'#tab2')
         return
 
@@ -1049,6 +1023,6 @@
             child_id = form['val_id']
         else:
-            self.flash(_('No study level selected.'))
-            self.redirect(self.url(self.context, '@@manage')+'?tab2')
+            self.flash(_('No study level selected.'), type="warning")
+            self.redirect(self.url(self.context, '@@manage')+'#tab2')
             return
         if not isinstance(child_id, list):
@@ -1063,5 +1037,5 @@
             self.context.writeLogMessage(
                 self,'removed: %s' % ', '.join(deleted))
-        self.redirect(self.url(self.context, u'@@manage')+'?tab2')
+        self.redirect(self.url(self.context, u'@@manage')+'#tab2')
         return
 
@@ -1082,12 +1056,6 @@
     def update(self, SUBMIT=None):
         super(StudentTranscriptRequestPage, self).update()
-        tabs.need()
-        self.tab1 = self.tab2 = ''
-        qs = self.request.get('QUERY_STRING', '')
-        if not qs:
-            qs = 'tab1'
-        setattr(self, qs, 'active')
         if not self.context.state == GRADUATED:
-            self.flash(_("Wrong state"))
+            self.flash(_("Wrong state"), type="danger")
             self.redirect(self.url(self.context))
             return
@@ -1106,8 +1074,9 @@
             code = get_access_code(pin)
             if not code:
-                self.flash(_('Activation code is invalid.'))
+                self.flash(_('Activation code is invalid.'), type="warning")
                 return
             if code.state == USED:
-                self.flash(_('Activation code has already been used.'))
+                self.flash(_('Activation code has already been used.'),
+                           type="warning")
                 return
             # Mark pin as used (this also fires a pin related transition)
@@ -1117,5 +1086,6 @@
             # expect an exception, but the owner might be different
             if not invalidate_accesscode(pin, comment, self.context.student_id):
-                self.flash(_('You are not the owner of this access code.'))
+                self.flash(_('You are not the owner of this access code.'),
+                           type="warning")
                 return
             self.context.clr_code = pin
@@ -1157,12 +1127,6 @@
     def update(self, SUBMIT=None):
         super(StudentTranscriptRequestProcessFormPage, self).update()
-        tabs.need()
-        self.tab1 = self.tab2 = ''
-        qs = self.request.get('QUERY_STRING', '')
-        if not qs:
-            qs = 'tab1'
-        setattr(self, qs, 'active')
         if self.context.state != TRANSCRIPT:
-            self.flash(_('Student is in wrong state.'))
+            self.flash(_('Student is in wrong state.'), type="warning")
             self.redirect(self.url(self.context))
             return
@@ -1222,5 +1186,6 @@
     def update(self):
         if not self.context.student.transcript_enabled:
-            self.flash(_('You are not allowed to view the transcript.'))
+            self.flash(_('You are not allowed to view the transcript.'),
+                       type="warning")
             self.redirect(self.url(self.context))
             return
@@ -1255,5 +1220,6 @@
     def update(self):
         if not self.context.student.transcript_enabled:
-            self.flash(_('You are not allowed to download the transcript.'))
+            self.flash(_('You are not allowed to download the transcript.'),
+                       type="warning")
             self.redirect(self.url(self.context))
             return
@@ -1319,18 +1285,16 @@
     pnav = 4
 
-    def update(self):
-        super(StudentTransferFormPage, self).update()
-        warning.need()
-        return
-
     @jsaction(_('Transfer'))
     def transferStudent(self, **data):
         error = self.context.transfer(**data)
         if error == -1:
-            self.flash(_('Current level does not match certificate levels.'))
+            self.flash(_('Current level does not match certificate levels.'),
+                       type="warning")
         elif error == -2:
-            self.flash(_('Former study course record incomplete.'))
+            self.flash(_('Former study course record incomplete.'),
+                       type="warning")
         elif error == -3:
-            self.flash(_('Maximum number of transfers exceeded.'))
+            self.flash(_('Maximum number of transfers exceeded.'),
+                       type="warning")
         else:
             self.flash(_('Successfully transferred.'))
@@ -1347,7 +1311,6 @@
 
     def update(self):
-        warning.need()
         if not self.context.has_key('studycourse_1'):
-            self.flash(_('No previous transfer.'))
+            self.flash(_('No previous transfer.'), type="warning")
             self.redirect(self.url(self.context))
             return
@@ -1375,5 +1338,4 @@
     def update(self):
         super(StudyLevelDisplayFormPage, self).update()
-        datatable.need()
         return
 
@@ -1486,4 +1448,5 @@
     tabtwoactions = [_('Add course ticket'),
         _('Remove selected tickets'),_('Cancel')]
+    placeholder = _('Enter valid course code')
 
     def update(self, ADD=None, course=None):
@@ -1492,25 +1455,17 @@
             return
         super(StudyLevelManageFormPage, self).update()
-        tabs.need()
-        self.tab1 = self.tab2 = ''
-        qs = self.request.get('QUERY_STRING', '')
-        if not qs:
-            qs = 'tab1'
-        setattr(self, qs, 'active')
-        warning.need()
-        datatable.need()
         if ADD is not None:
             if not course:
-                self.flash(_('No valid course code entered.'))
-                self.redirect(self.url(self.context, u'@@manage')+'?tab2')
+                self.flash(_('No valid course code entered.'), type="warning")
+                self.redirect(self.url(self.context, u'@@manage')+'#tab2')
                 return
             cat = queryUtility(ICatalog, name='courses_catalog')
             result = cat.searchResults(code=(course, course))
             if len(result) != 1:
-                self.flash(_('Course not found.'))
+                self.flash(_('Course not found.'), type="warning")
             else:
                 course = list(result)[0]
                 addCourseTicket(self, course)
-            self.redirect(self.url(self.context, u'@@manage')+'?tab2')
+            self.redirect(self.url(self.context, u'@@manage')+'#tab2')
         return
 
@@ -1539,6 +1494,6 @@
             child_id = form['val_id']
         else:
-            self.flash(_('No ticket selected.'))
-            self.redirect(self.url(self.context, '@@manage')+'?tab2')
+            self.flash(_('No ticket selected.'), type="warning")
+            self.redirect(self.url(self.context, '@@manage')+'#tab2')
             return
         if not isinstance(child_id, list):
@@ -1554,5 +1509,5 @@
                 self,'removed: %s at %s' %
                 (', '.join(deleted), self.context.level))
-        self.redirect(self.url(self.context, u'@@manage')+'?tab2')
+        self.redirect(self.url(self.context, u'@@manage')+'#tab2')
         return
 
@@ -1569,5 +1524,6 @@
             return
         if str(self.context.__parent__.current_level) != self.context.__name__:
-            self.flash(_('This level does not correspond current level.'))
+            self.flash(_('This level does not correspond current level.'),
+                       type="danger")
         elif self.context.student.state == REGISTERED:
             IWorkflowInfo(self.context.student).fireTransition(
@@ -1575,5 +1531,5 @@
             self.flash(_('Course list has been validated.'))
         else:
-            self.flash(_('Student is in the wrong state.'))
+            self.flash(_('Student is in the wrong state.'), type="warning")
         self.redirect(self.url(self.context))
         return
@@ -1594,5 +1550,6 @@
             return
         if str(self.context.__parent__.current_level) != self.context.__name__:
-            self.flash(_('This level does not correspond current level.'))
+            self.flash(_('This level does not correspond current level.'),
+                       type="danger")
             self.redirect(self.url(self.context))
             return
@@ -1606,5 +1563,5 @@
             self.flash(message)
         else:
-            self.flash(_('Student is in the wrong state.'))
+            self.flash(_('Student is in the wrong state.'), type="warning")
             self.redirect(self.url(self.context))
             return
@@ -1634,10 +1591,10 @@
         return
 
-    @action(_('Add course ticket'))
+    @action(_('Add course ticket'), style='primary')
     def addCourseTicket(self, **data):
         course = data['course']
         success = addCourseTicket(self, course)
         if success:
-            self.redirect(self.url(self.context, u'@@manage')+'?tab2')
+            self.redirect(self.url(self.context, u'@@manage')+'#tab2')
         return
 
@@ -1719,10 +1676,4 @@
             mapping = {'a':self.context.__parent__.display_fullname})
 
-    def update(self):
-        super(PaymentsManageFormPage, self).update()
-        datatable.need()
-        warning.need()
-        return
-
     @jsaction(_('Remove selected tickets'))
     def delPaymentTicket(self, **data):
@@ -1731,5 +1682,5 @@
             child_id = form['val_id']
         else:
-            self.flash(_('No payment selected.'))
+            self.flash(_('No payment selected.'), type="warning")
             self.redirect(self.url(self.context))
             return
@@ -1783,10 +1734,11 @@
                 self.flash(
                     _('Your current session does not match ' + \
-                    'accommodation session.'))
+                    'accommodation session.'), type="danger")
                 return
         if 'maintenance' in p_category:
             current_session = str(student['studycourse'].current_session)
             if not current_session in student['accommodation']:
-                self.flash(_('You have not yet booked accommodation.'))
+                self.flash(_('You have not yet booked accommodation.'),
+                           type="warning")
                 return
         students_utils = getUtility(IStudentsUtils)
@@ -1794,5 +1746,5 @@
             p_category, student, previous_session, previous_level)
         if error is not None:
-            self.flash(error)
+            self.flash(error, type="danger")
             return
         self.context[payment.p_id] = payment
@@ -1817,5 +1769,5 @@
     def update(self):
         if self.context.student.before_payment:
-            self.flash(_("No previous payment to be made."))
+            self.flash(_("No previous payment to be made."), type="warning")
             self.redirect(self.url(self.context))
         super(PreviousPaymentAddFormPage, self).update()
@@ -1832,5 +1784,5 @@
             p_category, student, previous_session, previous_level)
         if error is not None:
-            self.flash(error)
+            self.flash(error, type="danger")
             return
         self.context[payment.p_id] = payment
@@ -1865,5 +1817,5 @@
             balance_level, balance_amount)
         if error is not None:
-            self.flash(error)
+            self.flash(error, type="danger")
             return
         self.context[payment.p_id] = payment
@@ -1989,14 +1941,9 @@
             mapping = {'a':self.context.__parent__.display_fullname})
 
-    def update(self):
-        super(AccommodationManageFormPage, self).update()
-        datatable.need()
-        warning.need()
-        return
-
     @jsaction(_('Remove selected'))
     def delBedTickets(self, **data):
         if getattr(self.request.principal, 'user_type', None) == 'student':
-            self.flash(_('You are not allowed to remove bed tickets.'))
+            self.flash(_('You are not allowed to remove bed tickets.'),
+                       type="warning")
             self.redirect(self.url(self.context))
             return
@@ -2005,5 +1952,5 @@
             child_id = form['val_id']
         else:
-            self.flash(_('No bed ticket selected.'))
+            self.flash(_('No bed ticket selected.'), type="warning")
             self.redirect(self.url(self.context))
             return
@@ -2057,15 +2004,16 @@
                     enddate, tz).strftime("%d/%m/%Y %H:%M:%S")
                 self.flash(_("Outside booking period: ${a} - ${b}",
-                    mapping = {'a': startdate, 'b': enddate}))
+                    mapping = {'a': startdate, 'b': enddate}), type="warning")
             else:
-                self.flash(_("Outside booking period."))
+                self.flash(_("Outside booking period."), type="warning")
             self.redirect(self.url(self.context))
             return
         if not acc_details:
-            self.flash(_("Your data are incomplete."))
+            self.flash(_("Your data are incomplete."), type="warning")
             self.redirect(self.url(self.context))
             return
         if not student.state in acc_details['allowed_states']:
-            self.flash(_("You are in the wrong registration state."))
+            self.flash(_("You are in the wrong registration state."),
+                       type="warning")
             self.redirect(self.url(self.context))
             return
@@ -2073,5 +2021,6 @@
             'booking_session']:
             self.flash(
-                _('Your current session does not match accommodation session.'))
+                _('Your current session does not match accommodation session.'),
+                type="warning")
             self.redirect(self.url(self.context))
             return
@@ -2079,5 +2028,5 @@
             self.flash(
                 _('You already booked a bed space in current ' \
-                    + 'accommodation session.'))
+                    + 'accommodation session.'), type="warning")
             self.redirect(self.url(self.context))
             return
@@ -2091,5 +2040,5 @@
             code = get_access_code(pin)
             if not code:
-                self.flash(_('Activation code is invalid.'))
+                self.flash(_('Activation code is invalid.'), type="warning")
                 return
         # Search and book bed
@@ -2103,5 +2052,6 @@
             # XXX: Can be remove if nobody complains.
             if bed.__parent__.__parent__ is None:
-                self.flash(_('System error: Please contact the adminsitrator.'))
+                self.flash(_('System error: Please contact the adminsitrator.'),
+                           type="danger")
                 self.context.writeLogMessage(self, 'fatal error: %s' % bed.bed_id)
                 return
@@ -2118,5 +2068,6 @@
                 # XXX: Can be remove if nobody complains.
                 if bed.__parent__.__parent__ is None:
-                    self.flash(_('System error: Please contact the adminsitrator.'))
+                    self.flash(_('System error: Please contact the adminsitrator.'),
+                               type="warning")
                     self.context.writeLogMessage(self, 'fatal error: %s' % bed.bed_id)
                     return
@@ -2124,10 +2075,11 @@
             else:
                 self.flash(_('There is no free bed in your category ${a}.',
-                    mapping = {'a':acc_details['bt']}))
+                    mapping = {'a':acc_details['bt']}), type="warning")
                 return
         if self.with_ac:
             # Mark pin as used (this also fires a pin related transition)
             if code.state == USED:
-                self.flash(_('Activation code has already been used.'))
+                self.flash(_('Activation code has already been used.'),
+                           type="warning")
                 return
             else:
@@ -2137,5 +2089,6 @@
                 if not invalidate_accesscode(
                     pin,comment,self.context.student.student_id):
-                    self.flash(_('You are not the owner of this access code.'))
+                    self.flash(_('You are not the owner of this access code.'),
+                               type="warning")
                     return
         # Create bed ticket
@@ -2231,5 +2184,6 @@
         if self.context.bed != None and \
               'reserved' in self.context.bed.bed_type:
-            self.flash(_("Students in reserved beds can't be relocated."))
+            self.flash(_("Students in reserved beds can't be relocated."),
+                       type="warning")
             self.redirect(self.url(self.context))
             return
@@ -2237,5 +2191,5 @@
                 self.context.bed != None and \
                 self.context.bed.bed_type == self.context.bed_type:
-            self.flash(_("Student can't be relocated."))
+            self.flash(_("Student can't be relocated."), type="warning")
             self.redirect(self.url(self.context))
             return
@@ -2260,5 +2214,5 @@
             else:
                 self.flash(_('There is no free bed in your category ${a}.',
-                    mapping = {'a':acc_details['bt']}))
+                    mapping = {'a':acc_details['bt']}), type="warning")
                 self.redirect(self.url(self.context))
                 return
@@ -2343,5 +2297,5 @@
                 self.flash(_('Password changed.'))
             else:
-                self.flash( ' '.join(errors))
+                self.flash( ' '.join(errors), type="warning")
         return
 
@@ -2391,13 +2345,13 @@
     def update(self, SUBMIT=None):
         if not self.context.state == ADMITTED:
-            self.flash(_("Wrong state"))
+            self.flash(_("Wrong state"), type="warning")
             self.redirect(self.url(self.context))
             return
         if not self.portrait_uploaded:
-            self.flash(_("No portrait uploaded."))
+            self.flash(_("No portrait uploaded."), type="warning")
             self.redirect(self.url(self.context, 'change_portrait'))
             return
         if not self.all_required_fields_filled:
-            self.flash(_("Not all required fields filled."))
+            self.flash(_("Not all required fields filled."), type="warning")
             self.redirect(self.url(self.context, 'edit_base'))
             return
@@ -2411,8 +2365,9 @@
             code = get_access_code(pin)
             if not code:
-                self.flash(_('Activation code is invalid.'))
+                self.flash(_('Activation code is invalid.'), type="warning")
                 return
             if code.state == USED:
-                self.flash(_('Activation code has already been used.'))
+                self.flash(_('Activation code has already been used.'),
+                           type="warning")
                 return
             # Mark pin as used (this also fires a pin related transition)
@@ -2422,5 +2377,6 @@
             # expect an exception, but the owner might be different
             if not invalidate_accesscode(pin, comment, self.context.student_id):
-                self.flash(_('You are not the owner of this access code.'))
+                self.flash(_('You are not the owner of this access code.'),
+                           type="warning")
                 return
             self.context.clr_code = pin
@@ -2469,5 +2425,5 @@
         self.applyData(self.context, **data)
         if self.dataNotComplete():
-            self.flash(self.dataNotComplete())
+            self.flash(self.dataNotComplete(), type="warning")
             return
         self.flash(_('Clearance form has been saved.'))
@@ -2482,5 +2438,6 @@
                 # This shouldn't happen, but the application officer
                 # might have forgotten to lock the form after changing the state
-                self.flash(_('This form cannot be submitted. Wrong state!'))
+                self.flash(_('This form cannot be submitted. Wrong state!'),
+                           type="danger")
                 return
             IWorkflowInfo(self.context).fireTransition('request_clearance')
@@ -2510,5 +2467,5 @@
             pin = '%s-%s-%s' % (self.ac_prefix, self.ac_series, self.ac_number)
             if self.context.clr_code and self.context.clr_code != pin:
-                self.flash(_("This isn't your CLR access code."))
+                self.flash(_("This isn't your CLR access code."), type="danger")
                 return
         state = IWorkflowState(self.context).getState()
@@ -2516,5 +2473,6 @@
             # This shouldn't happen, but the application officer
             # might have forgotten to lock the form after changing the state
-            self.flash(_('This form cannot be submitted. Wrong state!'))
+            self.flash(_('This form cannot be submitted. Wrong state!'),
+                       type="danger")
             return
         IWorkflowInfo(self.context).fireTransition('request_clearance')
@@ -2541,5 +2499,6 @@
         super(StartSessionPage, self).update()
         if not self.context.next_session_allowed:
-            self.flash(_("You are not entitled to start session."))
+            self.flash(_("You are not entitled to start session."),
+                       type="warning")
             self.redirect(self.url(self.context))
             return
@@ -2553,9 +2512,10 @@
             code = get_access_code(pin)
             if not code:
-                self.flash(_('Activation code is invalid.'))
+                self.flash(_('Activation code is invalid.'), type="warning")
                 return
             # Mark pin as used (this also fires a pin related transition)
             if code.state == USED:
-                self.flash(_('Activation code has already been used.'))
+                self.flash(_('Activation code has already been used.'),
+                           type="warning")
                 return
             else:
@@ -2565,5 +2525,6 @@
                 if not invalidate_accesscode(
                     pin,comment,self.context.student.student_id):
-                    self.flash(_('You are not the owner of this access code.'))
+                    self.flash(_('You are not the owner of this access code.'),
+                               type="warning")
                     return
         try:
@@ -2578,5 +2539,6 @@
                     'pay_pg_fee')
         except ConstraintNotSatisfied:
-            self.flash(_('An error occurred, please contact the system administrator.'))
+            self.flash(_('An error occurred, please contact the system administrator.'),
+                       type="danger")
             return
         self.flash(_('Session started.'))
@@ -2607,4 +2569,9 @@
         if self.context.student.state != PAID:
             emit_lock_message(self)
+            return
+        code = self.context.current_level
+        if code is None:
+            self.flash(_('Your data are incomplete'), type="danger")
+            self.redirect(self.url(self.context))
             return
         super(AddStudyLevelFormPage, self).update()
@@ -2620,7 +2587,7 @@
                 self.context.certificate,studylevel)
         except KeyError:
-            self.flash(_('This level exists.'))
+            self.flash(_('This level exists.'), type="warning")
         except RequiredMissing:
-            self.flash(_('Your data are incomplete'))
+            self.flash(_('Your data are incomplete'), type="danger")
         self.redirect(self.url(self.context))
         return
@@ -2646,14 +2613,12 @@
             return
         super(StudyLevelEditFormPage, self).update()
-        datatable.need()
-        warning.need()
         if ADD is not None:
             if not course:
-                self.flash(_('No valid course code entered.'))
+                self.flash(_('No valid course code entered.'), type="warning")
                 return
             cat = queryUtility(ICatalog, name='courses_catalog')
             result = cat.searchResults(code=(course, course))
             if len(result) != 1:
-                self.flash(_('Course not found.'))
+                self.flash(_('Course not found.'), type="warning")
                 return
             course = list(result)[0]
@@ -2679,5 +2644,5 @@
             child_id = form['val_id']
         else:
-            self.flash(_('No ticket selected.'))
+            self.flash(_('No ticket selected.'), type="warning")
             self.redirect(self.url(self.context, '@@edit'))
             return
@@ -2710,5 +2675,5 @@
             self.flash(_(
                 "You are a postgraduate student, "
-                "your course list can't bee registered."))
+                "your course list can't bee registered."), type="warning")
             self.redirect(self.url(self.context))
             return
@@ -2717,5 +2682,5 @@
         if self.context.total_credits > max_credits:
             self.flash(_('Maximum credits of ${a} exceeded.',
-                mapping = {'a':max_credits}))
+                mapping = {'a':max_credits}), type="warning")
             return
         IWorkflowInfo(self.context.student).fireTransition(
@@ -2776,8 +2741,8 @@
             searchtype='reg_number', view=self)
         if not hitlist:
-            self.flash(_('No student found.'))
+            self.flash(_('No student found.'), type="warning")
             return
         if len(hitlist) != 1:   # Cannot happen but anyway
-            self.flash(_('More than one student found.'))
+            self.flash(_('More than one student found.'), type="warning")
             return
         student = hitlist[0].context
@@ -2787,5 +2752,5 @@
         code = get_access_code(pin)
         if not code:
-            self.flash(_('Access code is invalid.'))
+            self.flash(_('Access code is invalid.'), type="warning")
             return
         if student_pw and pin == student.adm_code:
@@ -2797,10 +2762,10 @@
             self.flash(
                 _('Password has already been set. You are using the ' +
-                'wrong Access Code.'))
+                'wrong Access Code.'), type="warning")
             return
         # Mark pin as used (this also fires a pin related transition)
         # and set student password
         if code.state == USED:
-            self.flash(_('Access code has already been used.'))
+            self.flash(_('Access code has already been used.'), type="warning")
             return
         else:
@@ -2860,5 +2825,5 @@
             student = results[0]
             if getattr(student,'firstname',None) is None:
-                self.flash(_('An error occurred.'))
+                self.flash(_('An error occurred.'), type="danger")
                 return
             elif student.firstname.lower() != firstname.lower():
@@ -2866,9 +2831,10 @@
                 # know that a record was found and only the firstname
                 # verification failed.
-                self.flash(_('No student record found.'))
+                self.flash(_('No student record found.'), type="warning")
                 return
             elif student.password is not None and self._pw_used:
                 self.flash(_('Your password has already been set and used. '
-                             'Please proceed to the login page.'))
+                             'Please proceed to the login page.'),
+                           type="warning")
                 return
             # Store email address but nothing else.
@@ -2877,5 +2843,5 @@
         else:
             # No record found, this is the truth.
-            self.flash(_('No student record found.'))
+            self.flash(_('No student record found.'), type="warning")
             return
 
@@ -2965,5 +2931,4 @@
 
     def update(self, SHOW=None, session=None, level=None):
-        datatable.need()
         self.parent_url = self.url(self.context.__parent__)
         self._set_session_values()
@@ -2988,5 +2953,5 @@
             self.hitlist = self._searchCatalog(self.session, self.level)
             if not self.hitlist:
-                self.flash(_('No student found.'))
+                self.flash(_('No student found.'), type="warning")
         return
 
@@ -3073,17 +3038,16 @@
             'configuration'].current_academic_session
         if self.context.__parent__.__parent__.score_editing_disabled:
-            self.flash(_('Score editing disabled.'))
+            self.flash(_('Score editing disabled.'), type="warning")
             self.redirect(self.url(self.context))
             return
         if not self.current_academic_session:
-            self.flash(_('Current academic session not set.'))
+            self.flash(_('Current academic session not set.'), type="warning")
             self.redirect(self.url(self.context))
             return
-        datatable.need()
         self.tickets = self._searchCatalog(self.current_academic_session)
         editable_tickets = [
             ticket for ticket in self.tickets if ticket.editable_by_lecturer]
         if not self.tickets:
-            self.flash(_('No student found.'))
+            self.flash(_('No student found.'), type="warning")
             self.redirect(self.url(self.context))
             return
@@ -3115,5 +3079,6 @@
             if error:
                 self.flash(_('Error: Score(s) of %s have not be updated. '
-                  'Only integers are allowed.' % error.strip(', ')))
+                  'Only integers are allowed.' % error.strip(', ')),
+                  type="danger")
         return
 
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/accommodationmanagepage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/accommodationmanagepage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/accommodationmanagepage.pt	(revision 11254)
@@ -2,5 +2,5 @@
       i18n:domain="waeup.kofa" enctype="multipart/form-data">
 
-  <table class="display dataTableManage">
+  <table class="kofa-data-table dataTableManage">
     <thead>
     <tr>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/basemanagepage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/basemanagepage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/basemanagepage.pt	(revision 11254)
@@ -3,13 +3,19 @@
       autocomplete="off">
 
-  <ul class="tabs" data-tabs="tabs">
-    <li tal:attributes="class view/tab1"><a href="#tab-1">
-    <span i18n:translate="">Base Data</span></a></li>
-    <li tal:attributes="class view/tab2"><a href="#tab-2">
-    <span i18n:translate="">Passport Picture</span></a></li>
+  <ul class="tabs nav nav-tabs" data-tabs="tabs">
+    <li class="active">
+      <a href="#tab1" data-toggle="tab">
+      <span i18n:translate="">Base Data</span></a>
+    </li>
+    <li>
+      <a href="#tab2" data-toggle="tab">
+        <span i18n:translate="">Passport Picture</span>
+      </a>
+    </li>
   </ul>
 
   <div class="tab-content">
-    <div id="tab-1" tal:attributes="class view/tab1">
+    <div id="tab1" class="active tab-pane">
+      <br />
       <table class="form-table">
         <tbody>
@@ -18,5 +24,5 @@
             <td class="fieldname" i18n:translate="">Password:</td>
             <td>
-              <input name="password" type="password"  />
+              <input name="password" class="form-control" type="password"  />
             </td>
           </tr>
@@ -24,5 +30,5 @@
             <td class="fieldname" i18n:translate="">Retype Password:</td>
             <td>
-              <input name="control_password" type="password" />
+              <input name="control_password" class="form-control" type="password" />
             </td>
           </tr>
@@ -38,5 +44,6 @@
     </div>
 
-    <div id="tab-2"  tal:attributes="class view/tab2">
+    <div id="tab2" class="tab-pane">
+      <br />
       <table class="form-table">
         <tbody>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/change_password.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/change_password.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/change_password.pt	(revision 11254)
@@ -10,5 +10,5 @@
         <td class="fieldname" i18n:translate="">Password:</td>
         <td>
-          <input name="change_password" type="password"  />
+          <input name="change_password" class="form-control" type="password"  />
         </td>
       </tr>
@@ -16,5 +16,5 @@
         <td class="fieldname" i18n:translate="">Retype Password:</td>
         <td>
-          <input name="change_password_repeat" type="password" />
+          <input name="change_password_repeat" class="form-control" type="password" />
         </td>
       </tr>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/clearanceeditpage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/clearanceeditpage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/clearanceeditpage.pt	(revision 11254)
@@ -2,12 +2,19 @@
       i18n:domain="waeup.kofa" enctype="multipart/form-data">
 
-  <ul class="tabs" data-tabs="tabs">
-    <li tal:attributes="class view/tab1"><a href="#tab-1">
-    <span i18n:translate="">Clearance Data</span></a></li>
-    <li tal:attributes="class view/tab2"><a href="#tab-2">
-    <span i18n:translate="">Scans</span></a></li>
+  <ul class="tabs nav nav-tabs" data-tabs="tabs">
+    <li class="active">
+      <a href="#tab1" data-toggle="tab">
+        <span i18n:translate="">Clearance Data</span>
+      </a>
+    </li>
+    <li>
+      <a href="#tab2" data-toggle="tab">
+        <span i18n:translate="">Scans</span>
+      </a>
+    </li>
   </ul>
   <div class="tab-content">
-    <div id="tab-1" tal:attributes="class view/tab1">
+    <div id="tab1" class="active tab-pane">
+      <br />
       <table class="form-table">
         <tbody>
@@ -23,5 +30,6 @@
     </div>
 
-    <div id="tab-2" tal:attributes="class view/tab2">
+    <div id="tab2" class="tab-pane">
+      <br />
       <table class="form-table">
         <tbody>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/containermanagepage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/containermanagepage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/containermanagepage.pt	(revision 11254)
@@ -1,21 +1,28 @@
-<form method="POST" i18n:domain="waeup.kofa">
+<form method="POST" i18n:domain="waeup.kofa" class="form-inline">
 <br />
-  <input class="btn primary" type="submit" name="search"
-    tal:attributes="value view/search_button" />
-
-  <select name="searchtype">
-    <option i18n:translate="" value="student_id">with id</option>
-    <option i18n:translate="" value="fullname">with name</option>
-    <option i18n:translate="" value="reg_number">with registration number</option>
-    <option i18n:translate="" value="matric_number">with matriculation number</option>
-    <option i18n:translate="" value="current_session">in session</option>
-    <option i18n:translate="" value="depcode">in department</option>
-    <option i18n:translate="" value="current_mode">in study mode</option>
-    <option i18n:translate="" value="suspended">
-      with deactivated account (search term omitted)
-    </option>
-  </select>
-
-  <input type="text" name="searchterm" />
+  <div class="form-group">
+    <input class="btn btn-primary" type="submit" name="search"
+      tal:attributes="value view/search_button" />
+  </div>
+  <div class="form-group">
+    <select name="searchtype" class="form-control">
+      <option i18n:translate="" value="student_id">with id</option>
+      <option i18n:translate="" value="fullname">with name</option>
+      <option i18n:translate="" value="reg_number">with registration number</option>
+      <option i18n:translate="" value="matric_number">with matriculation number</option>
+      <option i18n:translate="" value="current_session">in session</option>
+      <option i18n:translate="" value="depcode">in department</option>
+      <option i18n:translate="" value="current_mode">in study mode</option>
+      <option i18n:translate="" value="suspended">
+        with deactivated account (search term omitted)
+      </option>
+      <option i18n:translate="" value="transcript">
+        who requested transcript (search term omitted)
+      </option>
+    </select>
+  </div>
+  <div class="form-group">
+    <input type="text" class="form-control" name="searchterm" />
+  </div>
 
   <p>&nbsp;</p>
@@ -27,9 +34,6 @@
          tal:attributes="value view/searchtype" />
 
-    <input type="checkbox" onClick="toggle(this, 'entries')" />
-    <span  i18n:translate="">Select all</span>
     <br /><br />
-
-    <table class="display dataTableManage">
+    <table class="kofa-data-table dataTableManage">
       <thead>
     	<tr>
@@ -43,5 +47,5 @@
       </thead>
       <tbody>
-    	<tr tal:repeat="item view/hitlist" class="gradeC">
+    	<tr tal:repeat="item view/hitlist">
     	  <td><input type="checkbox" name="entries"
     	             tal:attributes="value item/context/__name__" /></td>
@@ -60,7 +64,9 @@
       </tbody>
     </table>
-    
+    <input type="checkbox" onClick="toggle(this, 'entries')" />
+    <span  i18n:translate="">Select all</span>
+    <br /><br />
     <input type="submit" name="remove"
-           tal:attributes="value view/remove_button" class="btn"
+           tal:attributes="value view/remove_button" class="btn btn-default"
            onclick="return confirmPost('Are you sure?')"/>
 
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/containerpage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/containerpage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/containerpage.pt	(revision 11254)
@@ -1,59 +1,62 @@
-<form method="POST" i18n:domain="waeup.kofa">
+<form method="POST" i18n:domain="waeup.kofa" class="form-inline">
 <br />
-  <input class="btn primary" type="submit" name="search"
-    tal:attributes="value view/search_button" />
-
-  <select name="searchtype">
-    <option i18n:translate="" value="student_id">with id</option>
-    <option i18n:translate="" value="fullname">with name</option>
-    <option i18n:translate="" value="reg_number">with registration number</option>
-    <option i18n:translate="" value="matric_number">with matriculation number</option>
-    <option i18n:translate="" value="current_session">in session</option>
-    <option i18n:translate="" value="depcode">in department</option>
-    <option i18n:translate="" value="current_mode">in study mode</option>
-    <option i18n:translate="" value="suspended">
-      with deactivated account (search term omitted)
-    </option>
-    <option i18n:translate="" value="transcript">
-      who requested transcript (search term omitted)
-    </option>
-  </select>
-
-  <input type="text" name="searchterm" />
-
-  <p>&nbsp;</p>
-  <div tal:condition="view/hitlist">
-    <h3 i18n:translate="">Search Results</h3>
-    <input type="hidden" name="old_searchterm"
-         tal:attributes="value view/searchterm" />
-    <input type="hidden" name="old_searchtype"
-         tal:attributes="value view/searchtype" />
-    <table class="display dataTable">
-      <thead>
-      <tr>
-        <th i18n:translate="">Student Id</th>
-        <th i18n:translate="">Reg. Number</th>
-        <th i18n:translate="">Matric. Number</th>
-        <th i18n:translate="">State</th>
-        <th i18n:translate="">Full Name</th>
-      </tr>
-      </thead>
-      <tbody>
-      <tr tal:repeat="item view/hitlist" class="gradeC">
-        <td> <a tal:attributes="href item/url">
-          <span tal:content="item/student_id">A123456</span></a>
-        </td>
-        <td class="center"> <a tal:attributes="href item/url">
-          <span tal:content="item/reg_number">9999999</span></a>
-        </td>
-        <td class="center"> <a tal:attributes="href item/url">
-          <span tal:content="item/matric_number">9999999</span></a>
-        </td>
-        <td tal:content="item/state">admitted</td>
-        <td tal:content="item/display_fullname">Bob</td>
-      </tr>
-      </tbody>
-    </table>
-    <br />
+  <div class="form-group">
+    <input class="btn btn-primary" type="submit" name="search"
+      tal:attributes="value view/search_button" />
+  </div>
+  <div class="form-group">
+    <select name="searchtype" class="form-control">
+      <option i18n:translate="" value="student_id">with id</option>
+      <option i18n:translate="" value="fullname">with name</option>
+      <option i18n:translate="" value="reg_number">with registration number</option>
+      <option i18n:translate="" value="matric_number">with matriculation number</option>
+      <option i18n:translate="" value="current_session">in session</option>
+      <option i18n:translate="" value="depcode">in department</option>
+      <option i18n:translate="" value="current_mode">in study mode</option>
+      <option i18n:translate="" value="suspended">
+        with deactivated account (search term omitted)
+      </option>
+      <option i18n:translate="" value="transcript">
+        who requested transcript (search term omitted)
+      </option>
+    </select>
+  </div>
+  <div class="form-group">
+    <input type="text" class="form-control" name="searchterm" />
   </div>
 </form>
+<br />
+<div tal:condition="view/hitlist">
+  <h3 i18n:translate="">Search Results</h3>
+  <input type="hidden" name="old_searchterm"
+       tal:attributes="value view/searchterm" />
+  <input type="hidden" name="old_searchtype"
+       tal:attributes="value view/searchtype" />
+  <table class="kofa-data-table dataTable">
+    <thead>
+    <tr>
+      <th i18n:translate="">Student Id</th>
+      <th i18n:translate="">Reg. Number</th>
+      <th i18n:translate="">Matric. Number</th>
+      <th i18n:translate="">State</th>
+      <th i18n:translate="">Full Name</th>
+    </tr>
+    </thead>
+    <tbody>
+    <tr tal:repeat="item view/hitlist">
+      <td> <a tal:attributes="href item/url">
+        <span tal:content="item/student_id">A123456</span></a>
+      </td>
+      <td class="center"> <a tal:attributes="href item/url">
+        <span tal:content="item/reg_number">9999999</span></a>
+      </td>
+      <td class="center"> <a tal:attributes="href item/url">
+        <span tal:content="item/matric_number">9999999</span></a>
+      </td>
+      <td tal:content="item/state">admitted</td>
+      <td tal:content="item/display_fullname">Bob</td>
+    </tr>
+    </tbody>
+  </table>
+</div>
+
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/editscorespage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/editscorespage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/editscorespage.pt	(revision 11254)
@@ -2,6 +2,5 @@
   <br />
 
-
-  <table class="display dataTable">
+  <table class="kofa-data-table dataTable">
     <thead>
   	<tr>
@@ -17,5 +16,5 @@
     </thead>
     <tbody>
-  	<tr tal:repeat="ticket view/tickets" class="gradeC">
+  	<tr tal:repeat="ticket view/tickets">
       <td tal:content="ticket/student/matric_number">MATRIC_NUMBER</td>
   	  <td tal:condition="ticket/editable_by_lecturer">
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/enterpin.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/enterpin.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/enterpin.pt	(revision 11254)
@@ -8,7 +8,7 @@
         <td>
         <span tal:replace="view/ac_prefix">PIN Prefix</span> -
-        <input name="ac_series" type="text" class="span1" maxlength="3"
+        <input name="ac_series" type="text" maxlength="3"
                value="" tal:attributes="value view/ac_series"/> -
-        <input name="ac_number" type="text" class="span3" maxlength="10"
+        <input name="ac_number" type="text" maxlength="10"
                value="" tal:attributes="value view/ac_number" />
         <font color="red"><span tal:replace="view/notice">Notice</span>
@@ -24,5 +24,5 @@
       <tr>
         <td colspan="2">
-          <input type="submit" name="SUBMIT" class="btn primary"
+          <input type="submit" name="SUBMIT" class="btn btn-primary"
                  tal:attributes="value view/buttonname" />
         </td>
@@ -36,5 +36,5 @@
       clicking the button below.
     </p>
-    <input type="submit" name="SUBMIT" class="btn primary"
+    <input type="submit" name="SUBMIT" class="btn btn-primary"
            tal:attributes="value view/buttonname" />
   </span>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportconfig.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportconfig.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportconfig.pt	(revision 11254)
@@ -1,3 +1,3 @@
-<p class="alert-message warning"  i18n:domain="waeup.kofa"
+<p class="alert alert-warning"  i18n:domain="waeup.kofa"
    i18n:translate="student_export_warning">
   <strong>NOTICE:</strong>
@@ -12,55 +12,45 @@
 <form i18n:domain="waeup.kofa" method="POST">
   <label for="mode" i18n:translate="">
-    Exporter (Data Type):
+    Exporter (Data Type)
   </label>
-  <div class="input">
-    <select name="exporter">
-      <option tal:repeat="item view/exporters"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">Students</span>
-      </option>
-    </select>
-  </div>
+  <select name="exporter" class="form-control half">
+    <option tal:repeat="item view/exporters"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">Students</span>
+    </option>
+  </select>
   <br />
   <label for="session" i18n:translate="">
-    Current Session:
+    Current Session
   </label>
-  <div class="input">
-    <select name="session">
-      <option tal:repeat="item view/sessions"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">2012/2013</span>
-      </option>
-    </select>
-  </div>
+  <select name="session" class="form-control half">
+    <option tal:repeat="item view/sessions"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">2012/2013</span>
+    </option>
+  </select>
   <br />
   <label for="level" i18n:translate="">
-    Current Level:
+    Current Level
   </label>
-  <div class="input">
-    <select name="level">
-      <option tal:repeat="item view/levels"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">200</span>
-      </option>
-    </select>
-  </div>
+  <select name="level" class="form-control half">
+    <option tal:repeat="item view/levels"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">200</span>
+    </option>
+  </select>
   <br />
   <label for="mode" i18n:translate="">
-    Current Study Mode:
+    Current Study Mode
   </label>
-  <div class="input">
-    <select name="mode">
-      <option tal:repeat="item view/modes"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">ug_ft</span>
-      </option>
-    </select>
-  </div>
+  <select name="mode" class="form-control half">
+    <option tal:repeat="item view/modes"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">ug_ft</span>
+    </option>
+  </select>
   <br /><br />
-  <div class="input">
   <input type="submit" name="START"  i18n:translate=""
     value="Create CSV file"
-    class="btn primary" />
-  </div>
+    class="btn btn-primary" />
 </form>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportconfig_certificate.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportconfig_certificate.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportconfig_certificate.pt	(revision 11254)
@@ -1,3 +1,3 @@
-<p class="alert-message warning"  i18n:domain="waeup.kofa"
+<p class="alert alert-warning"  i18n:domain="waeup.kofa"
    i18n:translate="student_export_warning">
   <strong>NOTICE:</strong>
@@ -12,43 +12,35 @@
 <form i18n:domain="waeup.kofa" method="POST">
   <label for="mode" i18n:translate="">
-    Exporter (Data Type):
+    Exporter (Data Type)
   </label>
-  <div class="input">
-    <select name="exporter">
-      <option tal:repeat="item view/exporters"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">Students</span>
-      </option>
-    </select>
-  </div>
+  <select name="exporter" class="form-control half">
+    <option tal:repeat="item view/exporters"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">Students</span>
+    </option>
+  </select>
   <br />
   <label for="session" i18n:translate="">
-    Current Session:
+    Current Session
   </label>
-  <div class="input">
-    <select name="session">
-      <option tal:repeat="item view/sessions"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">2012/2013</span>
-      </option>
-    </select>
-  </div>
+  <select name="session" class="form-control half">
+    <option tal:repeat="item view/sessions"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">2012/2013</span>
+    </option>
+  </select>
   <br />
   <label for="level" i18n:translate="">
-    Current Level:
+    Current Level
   </label>
-  <div class="input">
-    <select name="level">
-      <option tal:repeat="item view/levels"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">200</span>
-      </option>
-    </select>
-  </div>
+  <select name="level" class="form-control half">
+    <option tal:repeat="item view/levels"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">200</span>
+    </option>
+  </select>
   <br /><br />
-  <div class="input">
   <input type="submit" name="START"  i18n:translate=""
     value="Create CSV file"
-    class="btn primary" />
-  </div>
+    class="btn btn-primary" />
 </form>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportconfig_course.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportconfig_course.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportconfig_course.pt	(revision 11254)
@@ -1,43 +1,46 @@
+<p class="alert alert-warning"  i18n:domain="waeup.kofa"
+   i18n:translate="student_export_warning">
+  <strong>NOTICE:</strong>
+  Student data exports are very computation intensive.
+  Depending on the filter selected and the portal traffic load, exports may take
+  longer than 15 minutes. You are advised to export data outside high-traffic
+  time periods.
+</p>
+
+<br />
+
 <form i18n:domain="waeup.kofa" method="POST">
   <label for="mode" i18n:translate="">
-    Exporter (Data Type):
+    Exporter (Data Type)
   </label>
-  <div class="input">
-    <select name="exporter">
-      <option tal:repeat="item view/exporters"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">Students</span>
-      </option>
-    </select>
-  </div>
+  <select name="exporter" class="form-control half">
+    <option tal:repeat="item view/exporters"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">Students</span>
+    </option>
+  </select>
   <br />
   <label for="session" i18n:translate="">
-    Level Session:
+    Level Session
   </label>
-  <div class="input">
-    <select name="session">
-      <option tal:repeat="item view/sessions"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">2012/2013</span>
-      </option>
-    </select>
-  </div>
+  <select name="session" class="form-control half">
+    <option tal:repeat="item view/sessions"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">2012/2013</span>
+    </option>
+  </select>
   <br />
   <label for="level" i18n:translate="">
-    Level:
+    Level
   </label>
-  <div class="input">
-    <select name="level">
-      <option tal:repeat="item view/levels"
-              tal:attributes="value python:item[1]">
-        <span tal:replace="python: item[0]">200</span>
-      </option>
-    </select>
-  </div>
+  <select name="level" class="form-control half">
+    <option tal:repeat="item view/levels"
+            tal:attributes="value python:item[1]">
+      <span tal:replace="python: item[0]">200</span>
+    </option>
+  </select>
   <br /><br />
-  <div class="input">
   <input type="submit" name="START"  i18n:translate=""
     value="Create CSV file"
-    class="btn primary" />
-  </div>
+    class="btn btn-primary" />
 </form>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportjobsindex.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportjobsindex.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/exportjobsindex.pt	(revision 11254)
@@ -1,3 +1,3 @@
-<table i18n:domain="waeup.kofa">
+<table i18n:domain="waeup.kofa" class="table table-condensed">
   <thead>
     <tr>
@@ -25,5 +25,5 @@
         <span tal:replace="job/creator">CREATOR</span>
       </td>
-      <td nowrap>
+      <td>
         <span tal:replace="job/start_time">DATETIME</span>
       </td>
@@ -32,11 +32,11 @@
       </td>
       <td nowrap>
-        <a href="" class="btn" i18n:translate=""
+        <a href="" class="btn btn-default" i18n:translate=""
            tal:condition="job/show_refresh_button">
-          <img tal:attributes="src static/actionicon_reload.png" />
+          <img src="/static/img/actionicon_reload.png" />
           Reload
         </a>
         <form method="POST">
-          <a href="" class="btn primary small"
+          <a href="" class="btn btn-primary btn-xs"
                  tal:attributes="href job/download_url"
                  tal:condition="job/show_download_button">
@@ -45,5 +45,5 @@
           <input type="hidden" name="job_id"
                  tal:attributes="value job/job" />
-          <input type="submit" class="btn small"
+          <input type="submit" class="btn btn-default btn-xs"
                  name="DISCARD" value="Discard"
                  tal:condition="job/show_discard_button" />
@@ -53,9 +53,7 @@
   </tbody>
 </table>
+
 <form method="POST" i18n:domain="waeup.kofa">
-  <div class="span12">
-
-  </div>
-  <input class="btn primary" type="submit" name="CREATE"
+  <input class="btn btn-primary" type="submit" name="CREATE"
          value="Configure new export"
           />
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/filterstudentspage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/filterstudentspage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/filterstudentspage.pt	(revision 11254)
@@ -2,25 +2,22 @@
   <br />
   <label for="session">
-    <span tal:replace="view/session_label">SESSION</span>:
+    <span tal:replace="view/session_label">SESSION</span>
   </label>
-  <div class="input">
-    <select name="session">
-      <span tal:repeat="item view/sessions" tal:omit-tag="">
-        <option
-            tal:define="name python: item[1];
-                        title python: item[0];
-                        selected python: view.session_default == name"
-            tal:attributes="value name; selected selected">
-          <span tal:replace="title">TITLE</span>
-        </option>
-      </span>
-    </select>
-  </div>
+  <select name="session" class="form-control half">
+    <span tal:repeat="item view/sessions" tal:omit-tag="">
+      <option
+          tal:define="name python: item[1];
+                      title python: item[0];
+                      selected python: view.session_default == name"
+          tal:attributes="value name; selected selected">
+        <span tal:replace="title">TITLE</span>
+      </option>
+    </span>
+  </select>
   <br />
   <label for="levels">
-    <span tal:replace="view/level_label">LEVEL</span>:
+    <span tal:replace="view/level_label">LEVEL</span>
   </label>
-  <div class="input">
-  <select name="level">
+  <select name="level" class="form-control half">
     <span tal:repeat="item view/levels" tal:omit-tag="">
       <option
@@ -33,12 +30,9 @@
     </span>
   </select>
-  </div>
   <br /><br />
-  <div class="input">
-    <input i18n:translate="" type="submit" class="btn primary"
-           name="SHOW" value="Show" />
-    <a class="btn secondary" href=""
-       tal:attributes="href view/parent_url">Cancel</a>
-  </div>
+  <input i18n:translate="" type="submit" class="btn btn-primary"
+         name="SHOW" value="Show" />
+  <a class="btn btn-default" href=""
+     tal:attributes="href view/parent_url">Cancel</a>
 
   <br /><br />
@@ -51,5 +45,5 @@
       <span tal:replace="view/level_string">LEVEL</span>
     </h3>
-    <table class="display dataTable">
+    <table class="kofa-data-table dataTable">
       <thead>
     	<tr>
@@ -65,5 +59,5 @@
       </thead>
       <tbody>
-    	<tr tal:repeat="item view/hitlist" class="gradeC">
+    	<tr tal:repeat="item view/hitlist">
     	  <td> <a tal:attributes="href item/url"
                 target="_blank">
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/imagedisplay.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/imagedisplay.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/imagedisplay.pt	(revision 11254)
@@ -4,5 +4,6 @@
   </td>
   <td>
-      <img height="125px" tal:attributes="src viewlet/download_name" />
+      <img height="125px"
+         tal:attributes="src python: view.url(context, viewlet.download_name)" />
       <br />
   </td>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/imageupload.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/imageupload.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/imageupload.pt	(revision 11254)
@@ -5,9 +5,9 @@
   <td>
     <img align="middle" height="125px"
-         tal:attributes="src viewlet/download_name" />
+         tal:attributes="src python: view.url(context, viewlet.download_name)" />
     <input type="submit" tal:condition="viewlet/file_exists"
      tal:attributes="id python:('delete_%s' % viewlet.input_name);
         name python:('delete_%s' % viewlet.input_name)"
-     value="Delete" class="btn error" />
+     value="Delete" class="btn btn-danger" />
     <br /><br />
     <input type="file" tal:attributes="name viewlet/input_name"/>
@@ -17,5 +17,5 @@
                 name python:('upload_%s' % viewlet.input_name);
                 value viewlet/upload_button"
-             value="Upload" class="btn primary" />
+             value="Upload" class="btn btn-primary" />
     <span i18n:translate="">
       Max. file size:
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/loginasstep2.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/loginasstep2.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/loginasstep2.pt	(revision 11254)
@@ -9,5 +9,5 @@
   <input type="hidden" name="form.login" tal:attributes="value view/context/student_id" />
   <input type="hidden" name="form.password"   tal:attributes="value view/password" />
-  <input class="btn primary" type="submit" name="SUBMIT"
+  <input class="btn btn-primary" type="submit" name="SUBMIT"
     tal:attributes="value view/login_button" />
 </form>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/mydatadropdowntabs.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/mydatadropdowntabs.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/mydatadropdowntabs.pt	(revision 11254)
@@ -1,5 +1,8 @@
-<li tal:attributes="class viewlet/active" data-dropdown="dropdown" >
+<li  tal:attributes="class viewlet/active">
   <a href="#" class="dropdown-toggle"
-    tal:content="viewlet/tab_title">Tab Title</a>
+     data-toggle="dropdown">
+     <span tal:replace="viewlet/tab_title">My Data</span>
+     <b class="caret"></b>
+  </a>
   <ul class="dropdown-menu">
     <li tal:repeat="target viewlet/targets">
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/onlinepaymentaddform.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/onlinepaymentaddform.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/onlinepaymentaddform.pt	(revision 11254)
@@ -8,5 +8,6 @@
         </td>
         <td>
-          <select id="form.p_category" name="form.p_category" size="1" >
+          <select id="form.p_category" name="form.p_category" size="1"
+                  class="form-control half">
             <option tal:repeat="item view/selectable_categories"
                     tal:attributes="value python:item[0]">
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/paymentsmanagepage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/paymentsmanagepage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/paymentsmanagepage.pt	(revision 11254)
@@ -2,5 +2,5 @@
       i18n:domain="waeup.kofa" enctype="multipart/form-data">
 
-  <table class="display dataTableManage">
+  <table class="kofa-data-table dataTableManage">
     <thead>
     <tr>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studycoursemanagepage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studycoursemanagepage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studycoursemanagepage.pt	(revision 11254)
@@ -2,15 +2,20 @@
       i18n:domain="waeup.kofa" enctype="multipart/form-data">
 
-  <ul class="tabs" data-tabs="tabs">
-    <li tal:attributes="class view/tab1"><a href="#tab-1">
-      <span i18n:translate="">Study Course Data</span></a>
+  <ul class="tabs nav nav-tabs" data-tabs="tabs">
+    <li class="active">
+      <a href="#tab1" data-toggle="tab">
+        <span i18n:translate="">Study Course Data</span>
+      </a>
     </li>
-    <li tal:attributes="class view/tab2"><a href="#tab-2">
-      <span i18n:translate="">Study Levels</span></a>
+    <li t>
+      <a href="#tab2" data-toggle="tab">
+        <span i18n:translate="">Study Levels</span>
+      </a>
     </li>
   </ul>
 
   <div class="tab-content">
-    <div id="tab-1" tal:attributes="class view/tab1">
+    <div id="tab1" class="active tab-pane">
+      <br />
       <table class="form-table">
       <tbody>
@@ -27,7 +32,7 @@
     </div>
 
-    <div id="tab-2" tal:attributes="class view/tab2">
-      <h3 i18n:translate="">Study Levels (Course Lists)</h3>
-      <table class="display dataTableManage">
+    <div id="tab2" class="tab-pane">
+      <br />
+      <table class="kofa-data-table dataTableManage">
         <thead>
           <tr>
@@ -44,5 +49,5 @@
         		 tal:attributes="value cl/__name__" />
             </td>
-            <td> <a tal:attributes="href cl/__name__">
+            <td> <a tal:attributes="href python:view.url(cl)">
               <span tal:content="cl/level">CODE</span></a>
             </td>
@@ -62,26 +67,33 @@
       </div>
       <br /><br /><br />
-      <div>
+
+
+      <div class="form-inline">
         <span tal:condition="view/availableActions">
-          <span tal:repeat="action view/actions"
-                tal:omit-tag="">
-            <input tal:condition="python:action.label in view.tabthreeactions"
-                   tal:replace="structure action/render"/>
-          </span>
+          <div tal:repeat="action view/actions"
+              class="form-group">
+              <input tal:condition="python:action.label in view.tabthreeactions"
+                     tal:replace="structure action/render"/>
+          </div>
         </span>
-        <select id="addlevel" name="addlevel" class='span5'>
-          <option tal:attributes="value level/code" tal:repeat="level view/level_dicts">
-            <span tal:replace="level/title">LEVELTITLE
-          </span>
-          </option>
-        </select>
+        <div class="form-group">
+          <select id="addlevel" name="addlevel" class="form-control">
+            <option tal:attributes="value level/code" tal:repeat="level view/level_dicts">
+              <span tal:replace="level/title">LEVELTITLE
+            </span>
+            </option>
+          </select>
+        </div>
         &nbsp;&nbsp;<span i18n:translate="">in session</span>&nbsp;&nbsp;
-        <select id="level_session" name="level_session" class='span3'>
-          <option tal:attributes="value session/code" tal:repeat="session view/session_dicts">
-            <span tal:replace="session/title">LEVELSESSION
-          </span>
-          </option>
-        </select>
+        <div class="form-group">
+          <select id="level_session" name="level_session" class="form-control">
+            <option tal:attributes="value session/code" tal:repeat="session view/session_dicts">
+              <span tal:replace="session/title">LEVELSESSION
+            </span>
+            </option>
+          </select>
+        </div>
       </div>
+
     </div>
   </div>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studycoursepage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studycoursepage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studycoursepage.pt	(revision 11254)
@@ -64,5 +64,5 @@
 <h3 i18n:domain="waeup.kofa" i18n:translate="">Study Levels (Course Lists)</h3>
 
-<table i18n:domain="waeup.kofa">
+<table i18n:domain="waeup.kofa" class="table">
   <thead>
     <tr>
@@ -72,6 +72,6 @@
   </thead>
   <tbody>
-    <tr class="gradeC" tal:repeat="value context/values">
-      <td> <a tal:attributes="href value/__name__">
+    <tr tal:repeat="value context/values">
+      <td> <a tal:attributes="href python:view.url(value)">
       <span tal:content="value/level">CODE</span></a></td>
       <td tal:content="value/level_title">TITLE</td>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studyleveleditpage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studyleveleditpage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studyleveleditpage.pt	(revision 11254)
@@ -8,5 +8,5 @@
       tal:replace="view/context/total_credits">TOTAL</span>)
   </h3>
-  <table class="display dataTableManage">
+  <table class="kofa-data-table dataTableManage">
   <thead>
     <tr>
@@ -23,5 +23,5 @@
   </thead>
   <tbody>
-    <tr tal:repeat="value view/translated_values" class="gradeC">
+    <tr tal:repeat="value view/translated_values">
        <td>
         <input type="checkbox" name="val_id"
@@ -30,5 +30,5 @@
       </td>
       <td tal:content="value/semester" nowrap>TERM</td>
-      <td> <a tal:attributes="href value/__name__">
+      <td> <a tal:attributes="href value/url">
       <span tal:content="value/code">CODE</span>
       </a></td>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studylevelmanagepage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studylevelmanagepage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studylevelmanagepage.pt	(revision 11254)
@@ -2,15 +2,20 @@
       i18n:domain="waeup.kofa" enctype="multipart/form-data">
 
-  <ul class="tabs" data-tabs="tabs">
-    <li tal:attributes="class view/tab1"><a href="#tab-1">
-      <span i18n:translate="">Study Level Data</span></a>
+  <ul class="tabs nav nav-tabs" data-tabs="tabs">
+    <li class="active">
+      <a href="#tab1" data-toggle="tab">
+        <span i18n:translate="">Study Level Data</span>
+      </a>
     </li>
-    <li tal:attributes="class view/tab2"><a href="#tab-2">
-      <span i18n:translate="">Course Tickets</span>
-    </a></li>
+    <li>
+      <a href="#tab2" data-toggle="tab">
+        <span i18n:translate="">Course Tickets</span>
+      </a>
+    </li>
   </ul>
 
   <div class="tab-content">
-    <div id="tab-1" tal:attributes="class view/tab1">
+    <div id="tab1" class="active tab-pane">
+      <br />
       <table class="form-table">
       <tbody>
@@ -27,42 +32,42 @@
     </div>
 
-    <div id="tab-2" tal:attributes="class view/tab2">
-      <h3 i18n:translate="">Course Tickets</h3>
-      <table class="display dataTableManage">
-      <thead>
-        <tr>
-          <th>&nbsp;</th>
-          <th i18n:translate="">Term</th>
-          <th i18n:translate="">Code</th>
-          <th i18n:translate="">Title</th>
-          <th i18n:translate="">Dept.</th>
-          <th i18n:translate="">Fact.</th>
-          <th i18n:translate="">Cred.</th>
-          <th i18n:translate="">Requ.</th>
-          <th i18n:translate="">Score</th>
-          <th i18n:translate="">CO</th>
-          <th i18n:translate="">Auto</th>
-        </tr>
-      </thead>
-      <tbody>
-        <tr tal:repeat="value view/translated_values" class="gradeC">
-          <td>
-            <input type="checkbox" name="val_id"
-      		  tal:attributes="value value/__name__" />
-          </td>
-          <td tal:content="value/semester" nowrap>TERM</td>
-          <td> <a tal:attributes="href value/__name__">
-          <span tal:content="value/code">CODE</span>
-          </a></td>
-          <td tal:content="value/title">TITLE</td>
-          <td tal:content="value/dcode">DEPARTMENT</td>
-          <td tal:content="value/fcode">FACULTY</td>
-          <td tal:content="value/credits">CREDITS</td>
-          <td tal:content="value/mandatory">MANDATORY</td>
-          <td tal:content="value/score|nothing">SCORE</td>
-          <td tal:content="value/carry_over">CO</td>
-          <td tal:content="value/automatic">AUTO</td>
-        </tr>
-      </tbody>
+    <div id="tab2" class="tab-pane">
+      <br /><br />
+      <table class="kofa-data-table dataTableManage">
+        <thead>
+          <tr>
+            <th>&nbsp;</th>
+            <th i18n:translate="">Term</th>
+            <th i18n:translate="">Code</th>
+            <th i18n:translate="">Title</th>
+            <th i18n:translate="">Dept.</th>
+            <th i18n:translate="">Fact.</th>
+            <th i18n:translate="">Cred.</th>
+            <th i18n:translate="">Requ.</th>
+            <th i18n:translate="">Score</th>
+            <th i18n:translate="">CO</th>
+            <th i18n:translate="">Auto</th>
+          </tr>
+        </thead>
+        <tbody>
+          <tr tal:repeat="value view/translated_values">
+            <td>
+              <input type="checkbox" name="val_id"
+        		  tal:attributes="value value/__name__" />
+            </td>
+            <td tal:content="value/semester" nowrap>TERM</td>
+            <td> <a tal:attributes="href value/url">
+            <span tal:content="value/code">CODE</span>
+            </a></td>
+            <td tal:content="value/title">TITLE</td>
+            <td tal:content="value/dcode">DEPARTMENT</td>
+            <td tal:content="value/fcode">FACULTY</td>
+            <td tal:content="value/credits">CREDITS</td>
+            <td tal:content="value/mandatory">MANDATORY</td>
+            <td tal:content="value/score|nothing">SCORE</td>
+            <td tal:content="value/carry_over">CO</td>
+            <td tal:content="value/automatic">AUTO</td>
+          </tr>
+        </tbody>
       </table>
 
@@ -74,21 +79,17 @@
         </span>
       </div>
-
       <br /><br /><br />
-      <table class="input-table">
-        <tr>
-          <td>
-            <input class="btn primary" type="submit" name="ADD"
+      <div class="form-inline">
+        <div class="form-group">
+            <input class="btn btn-primary" type="submit" name="ADD"
                    i18n:translate=""
                    value="Add course ticket" />
-          </td>
-          <td>
-            <input type="text" name="course" />
-            <div class="hint" i18n:translate="">
-                Enter valid course code.
-            </div>
-          </td>
-        </tr>
-      </table>
+        </div>
+        <div class="form-group">
+            <input type="text" name="course" class="form-control"
+                   tal:attributes="placeholder view/placeholder" />
+        </div>
+      </div>
+      <br />
       <p i18n:translate="">
         You don't know the course code? Then select a course
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studylevelpage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studylevelpage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/studylevelpage.pt	(revision 11254)
@@ -1,5 +1,3 @@
 <table class="form-table" i18n:domain="waeup.kofa">
-  <thead>
-  </thead>
   <tbody>
     <tal:block repeat="widget view/widgets">
@@ -20,5 +18,5 @@
 <h3 i18n:domain="waeup.kofa" i18n:translate="">Course Tickets</h3>
 
-<table class="display dataTable" i18n:domain="waeup.kofa">
+<table class="kofa-data-table dataTable" i18n:domain="waeup.kofa">
   <thead>
     <tr>
@@ -37,7 +35,7 @@
   </thead>
   <tbody>
-    <tr tal:repeat="value view/translated_values" class="gradeC">
+    <tr tal:repeat="value view/translated_values">
       <td tal:content="value/semester" nowrap>TERM</td>
-      <td> <a tal:attributes="href value/__name__">
+      <td> <a tal:attributes="href value/url">
       <span tal:content="value/code">CODE</span>
       </a></td>
@@ -55,5 +53,4 @@
 </table>
 
-
 <div i18n:domain="waeup.kofa"
   tal:condition="python: not len(context.keys())" i18n:translate="">
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/transcript.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/transcript.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/transcript.pt	(revision 11254)
@@ -45,5 +45,5 @@
       <tal:semesters tal:repeat="semester_tickets python:(level['tickets_1'],
                                       level['tickets_2'], level['tickets_3'])">
-      <tr tal:repeat="ticket semester_tickets" class="gradeC">
+      <tr tal:repeat="ticket semester_tickets">
         <td tal:content="python: view.level_dict[ticket.level]">LEVEL</td>
         <td tal:content="python: view.session_dict[ticket.level_session]">SESSION</td>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/transcriptprocess.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/transcriptprocess.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/transcriptprocess.pt	(revision 11254)
@@ -1,13 +1,19 @@
 <form method="POST" i18n:domain="waeup.kofa">
 
-  <ul class="tabs" data-tabs="tabs">
-    <li tal:attributes="class view/tab1"><a href="#tab-1">
-    <span i18n:translate="">Process request</span></a></li>
-    <li tal:attributes="class view/tab2"><a href="#tab-2">
-    <span i18n:translate="">View correspondence</span></a></li>
+  <ul class="tabs nav nav-tabs" data-tabs="tabs">
+    <li class="active">
+      <a href="#tab1" data-toggle="tab">
+        <span i18n:translate="">Process request</span>
+      </a>
+    </li>
+    <li>
+      <a href="#tab2" data-toggle="tab">
+        <span i18n:translate="">View correspondence</span>
+      </a>
+    </li>
   </ul>
 
   <div class="tab-content">
-    <div id="tab-1" tal:attributes="class view/tab1">
+    <div id="tab1" class="active tab-pane">
 
       <table class="form-table">
@@ -32,5 +38,5 @@
     </div>
 
-    <div id="tab-2" tal:attributes="class view/tab2">
+    <div id="tab2" class="tab-pane">
       <p tal:content="structure view/correspondence"></p>
     </div>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/transcriptrequest.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/transcriptrequest.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/transcriptrequest.pt	(revision 11254)
@@ -1,13 +1,18 @@
 <form method="POST" i18n:domain="waeup.kofa">
 
-  <ul class="tabs" data-tabs="tabs">
-    <li tal:attributes="class view/tab1"><a href="#tab-1">
-    <span i18n:translate="">Send new request</span></a></li>
-    <li tal:attributes="class view/tab2"><a href="#tab-2">
-    <span i18n:translate="">View correspondence</span></a></li>
+  <ul class="tabs nav nav-tabs" data-tabs="tabs">
+    <li class="active">
+      <a href="#tab1" data-toggle="tab">
+        <span i18n:translate="">Send new request</span>
+      </a></li>
+    <li>
+      <a href="#tab2" data-toggle="tab">
+        <span i18n:translate="">View correspondence</span>
+      </a>
+    </li>
   </ul>
 
   <div class="tab-content">
-    <div id="tab-1" tal:attributes="class view/tab1">
+    <div id="tab1" class="active tab-pane">
 
       <p i18n:translate="transcript_request"></p>
@@ -65,5 +70,5 @@
     </div>
 
-    <div id="tab-2"  tal:attributes="class view/tab2">
+    <div id="tab2" class="tab-pane">
       <p tal:content="structure view/correspondence"></p>
     </div>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/trigtrans.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/trigtrans.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/browser_templates/trigtrans.pt	(revision 11254)
@@ -4,5 +4,5 @@
 
 
-    <select id="transition" name="transition">
+    <select id="transition" name="transition" class="form-control half">
       <option tal:repeat="transition view/getTransitions"
               tal:attributes="value transition/name">
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/dynamicroles.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/dynamicroles.py	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/dynamicroles.py	(revision 11254)
@@ -79,5 +79,5 @@
                     # Found a Course Adviser role in external attribute or parent
                     # thereof. We need a special treatment for Course Advisers.
-                    if str(100*(current_level/100)) in role_id:
+                    if current_level and str(100*(current_level/100)) in role_id:
                         # Grant additional role, which allows to validate or reject
                         # course lists, only if external role corresponds
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/reports/browser_templates/levelreportgeneratorpage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/reports/browser_templates/levelreportgeneratorpage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/reports/browser_templates/levelreportgeneratorpage.pt	(revision 11254)
@@ -7,59 +7,42 @@
   </p>
   <br />
-  <div class="clearfix">
-    <label for="session" i18n:translate="">Department:</label>
-    <div class="input">
-      <select name="faccode_depcode">
-        <span tal:repeat="items view/faccode_depcodes" tal:omit-tag="">
-          <option
-              tal:define="name python: items[1]; title python: items[0]"
-              tal:attributes="value name">
-            <span tal:replace="title">TITLE</span>
-          </option>
-        </span>
-      </select>
-      <div class="help-inline" i18n:translate="">
-        Set department filter.
-      </div>
-    </div>
-    <br />
-    <label for="session">Academic Session:</label>
-    <div class="input">
-      <select name="session" i18n:translate="">
-        <span tal:repeat="items view/sessions" tal:omit-tag="">
-          <option
-              tal:define="name python: items[1]; title python: items[0]"
-              tal:attributes="value name">
-            <span tal:replace="title">TITLE</span>
-          </option>
-        </span>
-      </select>
-      <div class="help-inline" i18n:translate="">
-        Select academic session to report.
-      </div>
-    </div>
-    <br />
-    <label for="session">Level:</label>
-    <div class="input">
-      <select name="level" i18n:translate="">
-        <span tal:repeat="items view/levels" tal:omit-tag="">
-          <option
-              tal:define="name python: items[1]; title python: items[0]"
-              tal:attributes="value name">
-            <span tal:replace="title">TITLE</span>
-          </option>
-        </span>
-      </select>
-      <div class="help-inline" i18n:translate="">
-        Select level to report.
-      </div>
-    </div>
-
+  <label for="session" i18n:translate="">Department</label>
+  <select name="faccode_depcode" class="form-control half">
+    <span tal:repeat="items view/faccode_depcodes" tal:omit-tag="">
+      <option
+          tal:define="name python: items[1]; title python: items[0]"
+          tal:attributes="value name">
+        <span tal:replace="title">TITLE</span>
+      </option>
+    </span>
+  </select>
+  <br />
+  <label for="session">Academic Session</label>
+  <div class="input">
+    <select name="session" i18n:translate="" class="form-control half">
+      <span tal:repeat="items view/sessions" tal:omit-tag="">
+        <option
+            tal:define="name python: items[1]; title python: items[0]"
+            tal:attributes="value name">
+          <span tal:replace="title">TITLE</span>
+        </option>
+      </span>
+    </select>
   </div>
-  <div class="input">
-    <input i18n:translate="" type="submit" class="btn primary"
-           name="CREATE" value="Create" />
-    <a class="btn secondary" href=""
-       tal:attributes="href view/parent_url">Cancel</a>
-  </div>
+  <br />
+  <label for="session">Level</label>
+  <select name="level" i18n:translate="" class="form-control half">
+    <span tal:repeat="items view/levels" tal:omit-tag="">
+      <option
+          tal:define="name python: items[1]; title python: items[0]"
+          tal:attributes="value name">
+        <span tal:replace="title">TITLE</span>
+      </option>
+    </span>
+  </select>
+  <br />
+  <input i18n:translate="" type="submit" class="btn btn-primary"
+         name="CREATE" value="Create" />
+  <a class="btn btn-default" href=""
+     tal:attributes="href view/parent_url">Cancel</a>
 </form>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/reports/browser_templates/studentstatisticsreportgeneratorpage.pt
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/reports/browser_templates/studentstatisticsreportgeneratorpage.pt	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/reports/browser_templates/studentstatisticsreportgeneratorpage.pt	(revision 11254)
@@ -7,43 +7,29 @@
   </p>
   <br />
-  <div class="clearfix">
-    <label for="session" i18n:translate="">Study Modes Group:</label>
-    <div class="input">
-      <select name="mode">
-        <span tal:repeat="items view/modes" tal:omit-tag="">
-          <option
-              tal:define="name python: items[1]; title python: items[0]"
-              tal:attributes="value name">
-            <span tal:replace="title">TITLE</span>
-          </option>
-        </span>
-      </select>
-      <div class="help-inline" i18n:translate="">
-        Set study modes filter.
-      </div>
-    </div>
-    <br />
-    <label for="session">Academic Session:</label>
-    <div class="input">
-      <select name="session" i18n:translate="">
-        <span tal:repeat="items view/sessions" tal:omit-tag="">
-          <option
-              tal:define="name python: items[1]; title python: items[0]"
-              tal:attributes="value name">
-            <span tal:replace="title">TITLE</span>
-          </option>
-        </span>
-      </select>
-      <div class="help-inline" i18n:translate="">
-        Select academic session to report.
-      </div>
-    </div>
-
-  </div>
-  <div class="input">
-    <input i18n:translate="" type="submit" class="btn primary"
-           name="CREATE" value="Create" />
-    <a class="btn secondary" href=""
-       tal:attributes="href view/parent_url">Cancel</a>
-  </div>
+  <label for="session" i18n:translate="">Study Modes Group</label>
+    <select name="mode" class="form-control half">
+      <span tal:repeat="items view/modes" tal:omit-tag="">
+        <option
+            tal:define="name python: items[1]; title python: items[0]"
+            tal:attributes="value name">
+          <span tal:replace="title">TITLE</span>
+        </option>
+      </span>
+    </select>
+  <br />
+  <label for="session">Academic Session</label>
+  <select name="session" i18n:translate="" class="form-control half">
+    <span tal:repeat="items view/sessions" tal:omit-tag="">
+      <option
+          tal:define="name python: items[1]; title python: items[0]"
+          tal:attributes="value name">
+        <span tal:replace="title">TITLE</span>
+      </option>
+    </span>
+  </select>
+  <br />
+  <input i18n:translate="" type="submit" class="btn btn-primary"
+         name="CREATE" value="Create" />
+  <a class="btn btn-default" href=""
+     tal:attributes="href view/parent_url">Cancel</a>
 </form>
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/reports/level_report.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/reports/level_report.py	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/reports/level_report.py	(revision 11254)
@@ -208,4 +208,5 @@
 from waeup.kofa.interfaces import academic_sessions_vocab
 from waeup.kofa.reports import get_generators
+from waeup.kofa.browser.breadcrumbs import Breadcrumb
 grok.templatedir('browser_templates')
 class LevelReportGeneratorPage(KofaPage):
@@ -291,2 +292,8 @@
             self.context.creation_dt_string)
 
+class LevelReportBreadcrumb(Breadcrumb):
+    """A breadcrumb for reports.
+    """
+    grok.context(LevelReportGenerator)
+    title = _(u'Level Report')
+    target = None
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/reports/session_results_presentation.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/reports/session_results_presentation.py	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/reports/session_results_presentation.py	(revision 11254)
@@ -198,4 +198,5 @@
 from waeup.kofa.interfaces import academic_sessions_vocab
 from waeup.kofa.reports import get_generators
+from waeup.kofa.browser.breadcrumbs import Breadcrumb
 grok.templatedir('browser_templates')
 class SessionResultsPresentationGeneratorPage(LevelReportGeneratorPage):
@@ -230,2 +231,9 @@
             self.context.sessioncode, self.context.levelcode,
             self.context.creation_dt_string)
+
+class SessionResultsPresentationBreadcrumb(Breadcrumb):
+    """A breadcrumb for reports.
+    """
+    grok.context(SessionResultsPresentationGenerator)
+    title = _(u'Session Results Presentation')
+    target = None
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/reports/student_statistics.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/reports/student_statistics.py	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/reports/student_statistics.py	(revision 11254)
@@ -168,4 +168,5 @@
 from waeup.kofa.interfaces import academic_sessions_vocab
 from waeup.kofa.reports import get_generators
+from waeup.kofa.browser.breadcrumbs import Breadcrumb
 grok.templatedir('browser_templates')
 class StudentStatisticsReportGeneratorPage(KofaPage):
@@ -240,2 +241,9 @@
             ob_class, self.context.__name__, filename))
         return pdf_stream
+
+class StudentStatsBreadcrumb(Breadcrumb):
+    """A breadcrumb for reports.
+    """
+    grok.context(StudentStatisticsReportGenerator)
+    title = _(u'Student Statistics')
+    target = None
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/tests/test_browser.py	(revision 11254)
@@ -613,5 +613,5 @@
         # There is a correct <img> link included
         self.assertTrue(
-            '<a target="image" href="birth_certificate">'
+            'href="http://localhost/app/students/K1000000/birth_certificate"'
             in self.browser.contents)
         # Browsing the link shows a real image
@@ -673,5 +673,5 @@
             name='upload_passportuploadmanage').click()
         self.assertTrue(
-            '<img align="middle" height="125px" src="passport.jpg" />'
+            'src="http://localhost/app/students/K1000000/passport.jpg"'
             in self.browser.contents)
         # We remove the passport file again
@@ -1958,5 +1958,8 @@
         # We are logged in as student and can see the 'My Data' tab
         self.assertMatches(
-            '...<a href="#" class="dropdown-toggle">My Data</a>...',
+            '...<a href="#" class="dropdown-toggle" data-toggle="dropdown">...',
+            self.browser.contents)
+        self.assertMatches(
+            '...My Data...',
             self.browser.contents)
         self.browser.getLink("Logout").click()
@@ -2198,5 +2201,5 @@
         self.browser.getControl("Login").click()
         self.assertMatches(
-            '...<div class="alert-message warning">'
+            '...<div class="alert alert-warning">'
             'Your account has been deactivated.</div>...', self.browser.contents)
         # If suspended_comment is set this message will be flashed instead
@@ -2206,5 +2209,5 @@
         self.browser.getControl("Login").click()
         self.assertMatches(
-            '...<div class="alert-message warning">Aetsch baetsch!</div>...',
+            '...<div class="alert alert-warning">Aetsch baetsch!</div>...',
             self.browser.contents)
         self.student.suspended = False
@@ -2265,5 +2268,5 @@
             name='upload_passportuploadedit').click()
         self.assertTrue(
-            '<img align="middle" height="125px" src="passport.jpg" />'
+            'src="http://localhost/app/students/K1000000/passport.jpg"'
             in self.browser.contents)
         # Students can open admission letter
@@ -2323,5 +2326,5 @@
             name='upload_birthcertificateupload').click()
         self.assertTrue(
-            '<a target="image" href="birth_certificate">Birth Certificate Scan</a>'
+            'href="http://localhost/app/students/K1000000/birth_certificate"'
             in self.browser.contents)
         # Students can open clearance slip
@@ -2358,4 +2361,9 @@
         # Now students can add the current study level
         self.browser.getLink("Study Course").click()
+        self.student['studycourse'].current_level = None
+        self.browser.getLink("Add course list").click()
+        self.assertMatches('...Your data are incomplete...',
+                           self.browser.contents)
+        self.student['studycourse'].current_level = 100
         self.browser.getLink("Add course list").click()
         self.assertMatches('...Add current level 100 (Year 1)...',
Index: main/waeup.kofa/trunk/src/waeup/kofa/students/viewlets.py
===================================================================
--- main/waeup.kofa/trunk/src/waeup/kofa/students/viewlets.py	(revision 10906)
+++ main/waeup.kofa/trunk/src/waeup/kofa/students/viewlets.py	(revision 11254)
@@ -825,5 +825,5 @@
     size = file_size(upload)
     if size > max_size:
-        view.flash(_('Uploaded file is too big.'))
+        view.flash(_('Uploaded file is too big.'), type="danger")
         return False
     upload.seek(0) # file pointer moved when determining size
@@ -831,5 +831,5 @@
     upload.seek(0) # same here
     if file_format is None:
-        view.flash(_('Could not determine file type.'))
+        view.flash(_('Could not determine file type.'), type="danger")
         return False
     basename, expected_ext = os.path.splitext(download_name)
@@ -837,5 +837,5 @@
         if '.' + file_format != expected_ext:
             view.flash(_('${a} file extension expected.',
-                mapping = {'a':expected_ext[1:]}))
+                mapping = {'a':expected_ext[1:]}), type="danger")
             return False
     else:
@@ -843,5 +843,6 @@
             view.flash(
                 _('Only the following extensions are allowed: ${a}',
-                mapping = {'a':', '.join(ALLOWED_FILE_EXTENSIONS)}))
+                mapping = {'a':', '.join(ALLOWED_FILE_EXTENSIONS)}),
+                type="danger")
             return False
         download_name += '.' + file_format
@@ -891,5 +892,5 @@
     template = default_fileupload_template
     grok.require('waeup.uploadStudentFile')
-    tab_redirect = '?tab2'
+    tab_redirect = '#tab2-top'
     mus = 1024 * 150
     upload_button =_('Upload new file')
@@ -931,5 +932,5 @@
                         self.context, self.view.__name__) + self.tab_redirect)
             else:
-                self.view.flash(_('No local file selected.'))
+                self.view.flash(_('No local file selected.'), type="danger")
                 self.view.redirect(
                     self.view.url(
@@ -959,5 +960,5 @@
     mus = 1024 * 50
     download_name = u'passport.jpg'
-    tab_redirect = '?tab2'
+    tab_redirect = '#tab2'
 
 class PassportUploadEdit(PassportUploadManage):
@@ -986,5 +987,5 @@
     mus = 1024 * 150
     download_name = u'birth_certificate'
-    tab_redirect = '?tab2'
+    tab_redirect = '#tab2-top'
 
 class Image(grok.View):
