Setting selected id for list through xml or json

Hi,

I’m generating a list from DB and need to set certain items as selected from the incoming url that gets loaded. I noticed that template_start has “obj.$selected”. Using "true or “selected:true” doesn’t seem to do anything. How do I set this value to true from the xml or json data that is being passed into the list so that selected ids are highlighted when the list is rendered?

Thanks!

In case of loading from json, existing code allows to use “$selected” flag in json object

{ "some":"value", "$selected":true }

and it will result in object selection
unfortunately there is no similar solution for xml