I use MagicSuggest
to populate a list of tags from the following JSON data:
{"Id":"money","name":"money"},{"Id":"education","name":"education"}]
while I'm going to edit the page, you need to pre-populate the selected tags: - as one pre-populated tag: money
Please suggest how I can set up a list of magic tips with pre-selected items.
Below is the code I've tried so far:
var article_tags = $('#article_tags').magicSuggest({
data: 'http://localhost:1043/Tag/TagData',
sortOrder: 'name',
valueField: 'name',
minChars: 0,
value: ['money'],
maxResults: false,
name: 'article_tags',
allowFreeEntries: false,
selectionPosition: 'right',
maxDropHeight: 200
});
source
share