common/tags.py
branchtls-sprint
changeset 1054 434e098f6c76
parent 980 59552ba2015f
child 1065 0a37f90acb13
equal deleted inserted replaced
1053:e4d965b5ca37 1054:434e098f6c76
    26 h2 = tag('h2')
    26 h2 = tag('h2')
    27 h3 = tag('h3')
    27 h3 = tag('h3')
    28 h4 = tag('h4')
    28 h4 = tag('h4')
    29 h5 = tag('h5')
    29 h5 = tag('h5')
    30 
    30 
    31 def select(name, id=None, multiple=False, options=[]):
    31 def select(name, id=None, multiple=False, options=[], **attrs):
    32     attrs = {}
       
    33     if multiple:
    32     if multiple:
    34         attrs['multiple'] = 'multiple'
    33         attrs['multiple'] = 'multiple'
    35     if id:
    34     if id:
    36         attrs['id'] = id
    35         attrs['id'] = id
    37     html = [u'<select name="%s" %s>' % (
    36     html = [u'<select name="%s" %s>' % (