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

swift - Button on Table View Cell connected to local function -

dns - Dokku server hosts two sites with TLD's, both domains are landing on only one app -

c# - ajax - How to receive data both html and json from server? -