jquery - Bootstrap Tags Input objects and json -


i trying use boorstrap tag input control located here:

http://timschlechter.github.io/bootstrap-tagsinput/examples/

in controller, creating list of selectlistitems:

       var tags = new list<selectlistitem>();          tags.add(new selectlistitem         {             value = "1",             text = "craig"         });          tags.add(new selectlistitem         {             value = "2",             text = "lister"         });           model.tags = tags; 

i pass model, 'tag' a:

public ienumerable tags { get; set; }

on view, render control:

                   <div class="row">                         <div class="col-xs-12">                             <label class="control-label text-right">tags:</label>                             <br />                             @html.textboxfor(x=>x.tags, new { @class= "form-control txttags", @data_role= "tagsinput" })                          </div>                     </div> 

however, instead of seeing tags, control renders drop down list 2 items.


Comments

Popular posts from this blog

c# - Binding a comma separated list to a List<int> in asp.net web api -

Delphi 7 and decode UTF-8 base64 -

html - Is there any way to exclude a single element from the style? (Bootstrap) -