knockout.js - Access to data out of foreach knockout -


i have 3 similar foreaches, them choose items (chekboxes), these items displayed in data-bind="foreach: selectedbooks" data-bind="text: bookname".

but, how can access choses items outside of used data-bind="foreach: allbooks" , display data in other place.

something data-bind="text: $root.username, $root.bookname, $root.somename" saving of order of selected items?

i tried use documentations http://knockoutjs.com/documentation/binding-context.html still doesn't work.

example http://jsfiddle.net/falkone/acdbrxy7/

you might want use knockout context debugger plugin chrome, it's useful when comes debugging mark up:

https://chrome.google.com/webstore/detail/knockoutjs-context-debugg/oddcpmchholgcjgjdnfjmildmlielhof?hl=en


Comments

Popular posts from this blog

google chrome - Developer tools - How to inspect the elements which are added momentarily (by JQuery)? -

angularjs - Showing an empty as first option in select tag -

php - Cloud9 cloud IDE and CakePHP -