Drag and drop sorting not working at all?


#1

Silly though it may be, I can’t get a list to be draggable. I haven’t
set up the update partials but I can’t even get the elements to become
draggable. Here is what my HTML output is:

  • John
  • Edward
  • Bill

The ERB for this is:
<%= sortable_element “Q#{question.position}_answer_list”,
:update => “Q#{question.position}_answers”,
:complete => visual_effect(:highlight,
“Q#{question.position}_answer_list”) %>

Why won’t these elements drag??? Thanks in advance.


#2

Taylor S. wrote:

Silly though it may be, I can’t get a list to be draggable. I haven’t
set up the update partials but I can’t even get the elements to become
draggable. Here is what my HTML output is:

Apparently drag and drop doesn’t work with just dragdrop.js as specified
in an older rails tutorial. You need the full prototype library. Using
javascript_include_tag :defaults fixed this issue.