hi, i''ve just started use prototype.js et al, i am currently creating a sortable list with: Sortable.create(''id'', { onChange: myFunc }); but what i really want is an event that occurs after the li''s have been reordered and settled into the new list order. how would i do that? i know i can do for exampe: Event.observe(''id'', ''mouseup'' , func , false); i''m sure there''s a very simple solution, it''s just escaping me, thanks for any tips. -brent -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails-spinoffs/attachments/20051014/5006d767/attachment.html
use onUpdate: I''m using it now with a sortable to do a window.location = <new location> Jamie On Oct 14, 2005, at 5:30 PM, Brent Pedersen wrote:> hi, > i''ve just started use prototype.js et al, i am currently creating a > sortable list with: > Sortable.create(''id'', { onChange: myFunc }); > > but what i really want is an event that occurs after the li''s have > been reordered and settled into the new list order. > > how would i do that? > > i know i can do for exampe: > > Event.observe(''id'', ''mouseup'' , func , false); > > i''m sure there''s a very simple solution, it''s just escaping me, > thanks for any tips. > -brent > _______________________________________________ > Rails-spinoffs mailing list > Rails-spinoffs@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs >
Use the onUpdate callback. See http://wiki.script.aculo.us/scriptaculous/show/Sortable.create for more info. Sorry for the wiki being down from time to time, it will be moved to a new server soon. Thomas Am 14.10.2005 um 23:30 schrieb Brent Pedersen:> hi, > i''ve just started use prototype.js et al, i am currently creating a > sortable list with: > Sortable.create(''id'', { onChange: myFunc }); > > but what i really want is an event that occurs after the li''s have > been reordered and settled into the new list order. > > how would i do that? > > i know i can do for exampe: > > Event.observe(''id'', ''mouseup'' , func , false); > > i''m sure there''s a very simple solution, it''s just escaping me, > thanks for any tips. > -brent > _______________________________________________ > Rails-spinoffs mailing list > Rails-spinoffs@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs >