Hello,

I'm trying to use the drag and drop in my web app so that users can
reposition images in their album.  But am not having much luck.  I've
implemented as follows:

header stuff...
<script src="/js/prototype.js" type="text/javascript"></script>
<script src="/js/common.js" type="text/javascript"></script>
<script src="/js/albums.js" type="text/javascript"></script>
<script src="/js/lightbox.js" type="text/javascript"></script>
<script src="/js/scriptaculous.js?load=effects,dragdrop"
type="text/javascript"></script>
<body>
    <ul id="album-images">

        <style type="text/css">.images { width: 70px; height: 70px;
}</style>

        <li class="images">
            <img src="blahblah..." />
        </li>

        <li class="images">
        </li>
    </ul>

    <script type="text/javascript">
        Sortable.create(
            "album-images",
            {
                dropOnEmpty: true,
                containment: "album-images",
                constraint: false
            }
        );
    </script>

</body>
</html>


I am getting to the following error:

    "element has no value  dragdrop.js line 584"

which is at:
      _findRootElement: function(element) {

It seems that the code is calling
  create: function(element) {
    element = $(element);

in "create:" and then calling, on line 592, in function options:

    element = Sortable._findRootElement($(element));

so $( $( "album-images" ) ) which of course is null


If I work around this error, I get the same error in prototype.js.
Since no one else is having this problem, I assume that I have done
something wrong.  I pulled the tarball 1.6.4 off the site just a few
days ago.

Thanks in advance for any help or ideas!!


--~--~---------~--~----~------------~-------~--~----~
 You received this message because you are subscribed to the Google Groups 
"Ruby on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to