def render(self, name, value, attrs=None, renderer=None):
    if (value is None):
        value = ''
    if DJANGO_11:
        final_attrs = self.build_attrs(attrs, extra_attrs={'name': name})
    else:
        final_attrs = self.build_attrs(attrs, name=name)
    final_attrs['class'] = 'nav nav-pills nav-stacked'
    output = [(u'<ul%s>' % flatatt(final_attrs))]
    options = self.render_options(force_text(value), final_attrs['id'])
    if options:
        output.append(options)
    output.append(u'</ul>')
    output.append(('<input type="hidden" id="%s_input" name="%s" value="%s"/>' % (final_attrs['id'], name, force_text(value))))
    return mark_safe(u'\n'.join(output))
def render(self, name, value, attrs=None, renderer=None):
    if (value is None):
        value = 
    if DJANGO_11:
        final_attrs = self.build_attrs(attrs, extra_attrs={'name': name})
    else:
        final_attrs = self.build_attrs(attrs, name=name)
    final_attrs['class'] = 'nav nav-pills nav-stacked'
    output = [(u'<ul%s>' % flatatt(final_attrs))]
    options = self.render_options(force_text(value), final_attrs['id'])
    if options:
        output.append(options)
    output.append(u'</ul>')
    output.append(('<input type="hidden" id="%s_input" name="%s" value="%s"/>' % (final_attrs['id'], name, force_text(value))))
    return mark_safe(u'\n'.join(output))