Dear Group,

I used the JQuery sortable function for this webpage:

http://variouselmts.com/development/projektil/

Here is the code I used:

                $(document).ready(function() {

                        $(".navigation a").click(function() {

                                var link = $(this);
                                var lang = link.attr("lang");
                                var href = "content/" + lang + "/" + 
link.attr("href");

                                $.ajax({url: href, cache: false, success: 
function(content) {

                                        $(".content[lang=" + lang + 
"]").prepend("<li>" + content + "</
li>");
                                        link.parent().css("display", "none");

                                        var h1 = $(".content[lang=" + lang + "] 
h1");

                                        h1.hover(function() {

                                                h1.css("cursor", "move");

                                                }, function() {

                                                h1.css("cursor", "default");


                                                });

                                        var getid = link.text();
                                        $(".content[lang=" + lang + 
"]").sortable({
                                                placeholder: "placeholder",
                                                handle: $("h1"),
                                                out: function(e, ui) {

                                                        
if(ui.absolutePosition.left > 200 || ui.absolutePosition.left <
0) {

                                                                var getid = 
ui.item.find("div").attr("id");
                                                                var geta = 
$(".navigation a:contains('" + getid + "')");
                                                                
geta.parent().css("display", "inline");
                                                                
ui.item.remove();

                                                                }

                                                        }
                                                });

                                        }});

                                return false;

                                });

                        });

It works pretty fine, but sometimes the code produces multiple
placeholders or other weird things,
can you try it and tell me if there is anything I can do about that?

Many Thanks

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"jQuery UI" 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/jquery-ui?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to