Changeset 1042 for WAeUP_SRP/trunk/skins/waeup_default
- Timestamp:
- 13 Dec 2006, 13:35:50 (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
WAeUP_SRP/trunk/skins/waeup_default/isStudent.py
r885 r1042 10 10 # $Id$ 11 11 12 #session = context.REQUEST.SESSION 13 #roles = member.getRolesInContext(context) 14 #return "Student" in roles 15 12 16 mtool = context.portal_membership 13 roles = mtool.getAuthenticatedMember().getRolesInContext(context) 14 return "Student" in roles 17 member = mtool.getAuthenticatedMember() 18 member_id = str(member) 19 if len(member_id) == 7: 20 try: 21 int(member_id[1:]) 22 return True 23 except: 24 return False
Note: See TracChangeset for help on using the changeset viewer.