Video module set up to store last location. Several bug fixes too.

This commit is contained in:
Piotr Mitros
2012-01-23 09:15:59 -05:00
parent d989621bff
commit ef1c465d5e
3 changed files with 27 additions and 16 deletions

View File

@@ -79,7 +79,9 @@ def id_tag(course):
if elem.get('id'):
pass
elif elem.get(default_ids[elem.tag]):
elem.set('id', elem.get(default_ids[elem.tag]))
new_id = elem.get(default_ids[elem.tag]) # Convert to alphanumeric
new_id = "".join([a for a in new_id if a.isalnum()])
elem.set('id', new_id)
else:
elem.set('id', fasthash(etree.tostring(elem)))