Search Results

Search found 98 results on 4 pages for 'droppable'.

Page 3/4 | < Previous Page | 1 2 3 4  | Next Page >

  • Getting ID of a cloned element

    - by Haris
    I'm using jQuery draggable and droppable. I'm cloning the draggable widget on drop event of droppable. I want to fetch the ID of the cloned element which will be sent to the the application with the AJAX request. I'm unable to fetch the ID. console.log returns blank string. var dropElem = ui.draggable.html(); var clone = $(dropElem).clone(); var widgetType = $(clone).attr('id'); $(this).append(clone); Also, I want to change the ID of the cloned element on the response event of the ajax request. How do I specially change the ID of the cloned event after it has been appended?

    Read the article

  • How to store result of drag and drop as a image

    - by Jimmy
    I want to take the screenshot of the result of drag and drop, but I don't know how to do. Actually, I found 2 javascript and using HTML5 such as html2canvas and canvas2image. I am now combining them together, but it's still meet some problem with the canvas2image. Please help me solve this problem if you have same experience, thank you a lot. Please help me, I've been stock here for days. Drag and drop code. <script> $(function() { $( "#draggable" ).draggable(); $( "#draggable2" ).draggable(); $( "#droppable" ).droppable({ hoverClass: "ui-state-active", drop: function( event, ui ) { $( this ) .addClass( "ui-state-highlight" ) .find( "p" ) .html( "Dropped!" ); } }); }); </script> Image generation code <script> window.onload = function() { function convertCanvas(strType) { if (strType == "JPEG") var oImg = Canvas2Image.saveAsJPEG(oCanvas, true); if (!oImg) { alert("Sorry, this browser is not capable of saving " + strType + " files!"); return false; } oImg.id = "canvasimage"; oImg.style.border = oCanvas.style.border; oCanvas.parentNode.replaceChild(oImg, oCanvas); } function convertHtml(strType) { $('body').html2canvas(); var queue = html2canvas.Parse(); var canvas = html2canvas.Renderer(queue,{elements:{length:1}}); var img = canvas.toDataURL(); convertCanvas(strType); window.open(img); } document.getElementById("html2canvasbtn").onclick = function() { convertHtml("JPEG"); } } </script> HTML code <body> <h3>Picture:</h3> <div id="draggable"> <img src='http://1.gravatar.com/avatar/1ea64135b09e00ab80fa7596fafbd340? s=50&d=identicon&r=R'> </div> <div id="draggable2"> <img src='http://0.gravatar.com/avatar/2647a7d4b4a7052d66d524701432273b?s=50&d=identicon&r=G'> </div> <div id="dCanvas"> <canvas id="droppable" width="500" height="500" style="border: 2px solid gray" class="ui-widget-header" /> </div> <input type="button" id="bGenImage" value="Generate Image" /> <div id="dOutput"></div> </body>

    Read the article

  • jquery draggable accept: classpath

    - by heldopslippers
    Hi guys.. I have problems with the following bit of javascript/jquery code: this.droppable = function(){ $('.imageWindow .body .item').draggable(); $('.groupWindow .body .item').droppable({ accept: $(".imageWindow .body .item"), over: function(event, ui) { alert("this is valid!"); }, drop: function(){ alert('dropped'); } }); } As you maybe know it is not possible to pass the following in the accept option: $(".imageWindow .body .item") But what is possible ? I want to pass a "class path" as an accept option ! It is probably a simple answer but i can't figure it out. Of course i could do: accept: ".item" But because "groupWindow .body .item" is a sortable it would also accept himself! Thanxs if you can help me!

    Read the article

  • how to make a div(black border,and on the google-maps) panel drop-disable,thanks

    - by zjm1126
    the black div is used to panel,so it can not be droppable. <!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.0//EN" "http://www.wapforum.org/DTD/xhtml-mobile10.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <meta name="viewport" content="width=device-width,minimum-scale=0.3,maximum-scale=5.0,user-scalable=yes"> </head> <body onload="initialize()" onunload="GUnload()"> <style type="text/css"> *{ margin:0; padding:0; } .container{ padding:10px; width:50px; height:50px; border:5px solid black; } </style> <!--<div style="width:100px;height:100px;background:blue;"> </div>--> <div id="map_canvas" style="width: 500px; height: 300px;"></div> <!-- <div class=b style="width: 20px; height: 20px;background:red;position:absolute;left:700px;top:200px;"></div> <div class=b style="width: 20px; height: 20px;background:red;position:absolute;left:700px;top:200px;"></div> <div class=b style="width: 20px; height: 20px;background:red;position:absolute;left:700px;top:200px;"></div> <div class=b style="width: 20px; height: 20px;background:red;position:absolute;left:700px;top:200px;"></div> <div class=b style="width: 20px; height: 20px;background:red;position:absolute;left:700px;top:200px;"></div> --> <script src="jquery-1.4.2.js" type="text/javascript"></script> <script src="jquery-ui-1.8rc3.custom.min.js" type="text/javascript"></script> <script src="http://maps.google.com/maps?file=api&amp;v=2&amp;key=ABQIAAAA-7cuV3vqp7w6zUNiN_F4uBRi_j0U6kJrkFvY4-OX2XYmEAa76BSNz0ifabgugotzJgrxyodPDmheRA&sensor=false"type="text/javascript"></script> <script type="text/javascript"> var aFn; //********** function initialize() { if (GBrowserIsCompatible()) { //************ function a() { } a.prototype = new GControl(); a.prototype.initialize = function(map) { var container = document.createElement("div"); var a=''; for(i=0;i<5;i++){ a+='<div class=b style="width: 20px; height: 20px;background:red;position:absolute;"></div>' } $(container).addClass('container'); $(container).droppable( 'destroy' ).css('z-index','2700') $(map.getContainer()).append($(container).append(a)); return container; } a.prototype.getDefaultPosition = function() { return new GControlPosition(G_ANCHOR_TOP_LEFT, new GSize(7, 7)); } //************ var map = new GMap2(document.getElementById("map_canvas")); map.addControl(new a()); var center=new GLatLng(39.9493, 116.3975); map.setCenter(center, 13); aFn=function(x,y){ var point =new GPoint(x,y) point = map.fromContainerPixelToLatLng(point); //console.log(point.x+" "+point.y) map.addOverlay(new GMarker(point)); } $(".b").draggable({}); $("#map_canvas").droppable({ drop: function(event,ui) { //console.log(ui.offset.left+' '+ui.offset.top) aFn(ui.offset.left+10,ui.offset.top+10); ui.draggable.remove(); } }); } } //************* </script> </body> </html>

    Read the article

  • jQuery - manipulate dropped element in sortable list

    - by WastedSpace
    Hi there, I have a draggable list (.field) where you can drag & drop items from it into a sortable list (.sortlist). I did it this way because I didn't want the master list (.field) altered in any way. It works fine, except I cannot work out how to manipulate the dropped field in a sortable list. I can do it from a draggable into a droppable area by using the following in a function for 'drop:' in droppable(): $(this).append('html code here to change content of dragged field'); However this doesn't work inside a sortable(). My code looks like this: $(".sortlist").sortable({ receive: function(event, ui) { var dropElemTxt = $(ui.item).text(); var dropElemId = $(ui.item).attr('id'); $(ui.item).replaceWith('<li class="box" id="'+dropElemId+'">Updated field! '+dropElemTxt+'</li>'); } }); $(ui.item).replaceWith changes the master field that was being dragged, so this doesn't work. And I tried $(this).replaceWith, but that updates the sortable area (.sortlist). Any idea what code I need to reference the dragged item? Many thanks, Ali.

    Read the article

  • how to make the red div don't alert 'ss' when drag the black div on it ,

    - by zjm1126
    i using jquery and jquery-ui, this is my code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta name="viewport" content="width=device-width, user-scalable=no"> </head> <body> <style type="text/css" media="screen"> </style> <div id=a style="width:300px;height:300px;background:blue;position:absolute;"></div> <div id=b style="width:100px;height:100px;background:red;position:absolute;"></div> <div id=c style="width:50px;height:50px;background:black;clear:both"></div> <script src="jquery-1.4.2.js" type="text/javascript"></script> <script src="jquery-ui-1.8rc3.custom.min.js" type="text/javascript"></script> <script type="text/javascript" charset="utf-8"> $("#c").draggable({}); $("#b").droppable('disable');//this is not useful $("#a").droppable({ drop: function(event,ui) { alert('ss') } }); </script> </body> </html>

    Read the article

  • Jquery drag /drop and clone

    - by Sajeev
    Hi I need to achive this .. I have a set of droppable items ( basically I am droping designs on a apparel ) and I am dropping a clone.. If I don't like the dropped object (designs) - I want to delete that by doing something like hidden . But I am unable to do that. Please help me.. here is the code var clone; $(document).ready(function(){ $(".items").draggable({helper: 'clone',cursor: 'hand'}); $(".droparea").droppable({ accept: ".items", hoverClass: 'dropareahover', tolerance: 'pointer', drop: function(ev, ui) { var dropElemId = ui.draggable.attr("id"); var dropElem = ui.draggable.html(); clone = $(dropElem).clone(); // clone it and hold onto the jquery object clone.id="newId"; clone.css("position", "absolute"); clone.css("top", ui.absolutePosition.top); clone.css("left", ui.absolutePosition.left); clone.draggable({ containment: 'parent' ,cursor: 'crosshair'}); $(this).append(clone); alert("done dragging "); /lets assume I have a delete button when I click that clone should dissapear so that I can drop another design - but the following code has no effect //and the item is still visible , how to make it dissapear ? $('#newId').css("visibility","hidden"); } }); });

    Read the article

  • jquery disable text box created after drag and drop

    - by user1736989
    I have two div one for tools where to drag and one for dropping in. html is <div id="popular"> <ul> <li class="dragfield" id="textfield">Text field</li> <li class="dragfield"id="textarea">Text area</li> <li class="dragfield"id="emailfield">email field</li> <li class="dragfield"id="dropdownselection">dropdown selection</li> <li class="dragfield"id="checkboxes">checkboxes</li> <li class="dragfield"id="multiplechoicecheckboxes">multiple choice checkboxes</li> </ul> </div> <div id="editable"> <p>hii</p> </div> and here is javascript for droppable $(function() { $('.dragfield').draggable(); $( "#editable" ).droppable({ drop: handletextDrop }); }); function handletextDrop( event, ui ) { var id = ui.draggable.attr("id"); if(id=="textfield") { var $Div = $('<div id="TextBoxDiv"></div>'); $Div.append('<label>Textbox</label>' + '<input type="text" name="textbox" id="textbox" value="" />'); $('#editable').append($Div); } } I want to make this textbox which is being created to remain disabled.javascript applying to id of these div e.g. #textbox etc. not working Is there any easy way in which i can include this html from some other page?

    Read the article

  • Qué control te gustaria?

    - by Jason Ulloa
    Cada vez, utilizó mas Jquery para enriquecer las aplicaciones que desarrollo, pero cada vez me doy cuenta de que siempre debo leer la documentación de los controles para poder recordar todas las funciones. Esto, sumado a la cantidad de código script que debo colocar en las páginas. Es por eso que decidi empezar a trabajar en una pequeña seríe de controles de Jquery para asp.net basado en el framework DJ Jquery. Por supuesto, una serie de controles OpenSource para la comunidad   Actualmente los controles disponibles son: * Accordion * Animation * Autocomplete * DatePicker * Dialog * Draggable * Droppable * Effect * FileUpload * FlexGrid (en desarrollo) * Floater Menu * JMenu (en desarrollo) * Jquery Plugin * Password Meter * ProgressBar * Resizable * Selectable * Slick Menu * Slider * Sortable * Tabs * ButtonEx * Toggle Button * Simple Button * Simple List View   Así que la idea es preguntarles: ¿Qué otro control les gustaría ver en la suite?   Saludos,

    Read the article

  • Treeview drag and drop

    - by David Thorisson
    I'm using the jQuery droppable/dragable to reorder a treeview (made up of ul/li items) I have no problems making a element and dragging it into the tree When I define the items to be draggable, the code doesn´t work any more (the items are classed as "droppables" but the drop event won´t run) Isn't this supposed to be possible?

    Read the article

  • Jquery simple photo manager demo - recycle trash completely

    - by Roman
    Hi, I'm using the Jquery's simple photo manager just as it is and it's working properly. http://jqueryui.com/demos/droppable/photo-manager.html All I need is the possibility to recycle all the elements from the trash by a single click. Sounds simple but I couldn't get it so far. Ok, I'm a newbie to Jquery. Help would be appreciated!

    Read the article

  • Scriptaculous Sortable.create - Can't hook the dragged element

    - by Tom
    When using Sortable.create I can't seem to get the element that is being dragged. Does Sciptaculous not fully implement all Draggable and Droppable features when you use sortable? Given: Sortable.create("sortArea", {scroll:window, onChange:orderLi}); function orderLi(){ console.log(this.draggables.each(function(e){if(e.dragging==true){return e};})); } My console always shows all the array of draggables. How do I only grab the one that is being dragged?

    Read the article

  • Draggable Clones Jquery?

    - by jbatson
    Any ideas on how to make the clones draggable? $("#draggable").draggable({ helper: 'clone', cursor: 'pointer', }); $("#snaptarget").droppable({ drop: function(event, ui) { var randomnumber = Math.floor(Math.random()*1000000); var newId = '#draggable_'+randomnumber; $(ui.helper).clone(true).removeAttr('id').attr('id',newId).appendTo('#snaptarget'); $(newId).draggable(); } }); $(newId).draggable(); does not work.

    Read the article

  • JQuery: calling ajax on drop element

    - by Lukasz Baran
    $("div.square").droppable({ accept: '.white', drop: function (event, ui) { $to = "#" + $(this).attr('id'); alert(to); $.post( "/Game/AddMove", { from: $from, to: $to, GameID: $("#gameID").val() }); } }); Well it's nor working. So I must ask, is it possible to call AJAX on droping some UI element ? The problem is, it's not even calling an controller,

    Read the article

  • Rails 3: How do I call a javascript function from a js.erb file

    - by user321775
    Now that I've upgraded to Rails 3, I'm trying to figure out the proper way to separate and reuse pieces of javascript. Here's the scenario I'm dealing with: I have a page with two areas: one with elements that should be draggable, the other with droppables. When the page loads I use jQuery to setup the draggables and droppables. Currently I have the script in the head portion of application.html.erb, which I'm sure is not the right solution but at least works. When I press a button on the page, an ajax call is made to my controller that replaces the draggables with a new set of elements that should also be draggable. I have a js.erb file that renders a partial in the correct location. After rendering I need to make the new elements draggable, so I'd like to reuse the code that currently lives in application.html.erb, but I haven't found the right way to do it. I can only make the new elements draggable by pasting the code directly into my js.erb file (yuck). What I'd like to have: - a javascript file that contains the functions prepdraggables() and prepdroppables() - a way to call either function from application.html.erb or from a js.erb file I've tried using :content_for to store and reuse the code, but can't seem to get it working correctly. What I currently have in the head section of application.html.erb <% content_for :drag_drop_prep do %> <script type="text/javascript" charset="utf-8"> $(document).ready(function () { // declare all DOM elements with class draggable to be draggable $( ".draggable" ).draggable( { revert : 'invalid' }); // declare all DOM elements with class legal to be droppable $(".legal").droppable({ hoverClass : 'legal_hover', drop : function(event, ui) { var c = new Object(); c['die'] = ui.draggable.attr("id"); c['cell'] = $(this).attr("id"); c['authenticity_token'] = encodeURIComponent(window._token); $.ajax({ type: "POST", url: "/placeDie", data: c, timeout: 5000 }); }}); }); </script> <% end %> undo.js.erb $("#board").html("<%= escape_javascript(render :partial => 'shared/board', :locals => { :playable => true, :restartable => !session[:challenge]}) %>") // This is where I want to prepare draggables. <%= javascript_include_tag "customdragdrop.js" %> // assuming this file had the draggables code from above in a prepdraggables() function prepdraggables();

    Read the article

  • jquery ui drag and drop + ajax problem

    - by mobster
    I'm making board game and i'm using jquery ui draggable effect for figures. On drag start I send ajax request to other page where I generate droppable places soo the figure can be drag and droped only on those particular places, but the problem is I must move figure twice to take effect. Does anyone know how to solve this problem? I would be very grateful for help.

    Read the article

  • Looking for a workaround for IE 6/7 "Unspecified Error" bug when accessing offsetParent; using ASP.N

    - by CodeChef
    I'm using jQuery UI's draggable and droppable libraries in a simple ASP.NET proof of concept application. This page uses the ASP.NET AJAX UpdatePanel to do partial page updates. The page allows a user to drop an item into a trashcan div, which will invoke a postback that deletes a record from the database, then rebinds the list (and other controls) that the item was drug from. All of these elements (the draggable items and the trashcan div) are inside an ASP.NET UpdatePanel. Here is the dragging and dropping initialization script: function initDragging() { $(".person").draggable({helper:'clone'}); $("#trashcan").droppable({ accept: '.person', tolerance: 'pointer', hoverClass: 'trashcan-hover', activeClass: 'trashcan-active', drop: onTrashCanned }); } $(document).ready(function(){ initDragging(); var prm = Sys.WebForms.PageRequestManager.getInstance(); prm.add_endRequest(function() { initDragging(); }); }); function onTrashCanned(e,ui) { var id = $('input[id$=hidID]', ui.draggable).val(); if (id != undefined) { $('#hidTrashcanID').val(id); __doPostBack('btnTrashcan',''); } } When the page posts back, partially updating the UpdatePanel's content, I rebind the draggables and droppables. When I then grab a draggable with my cursor, I get an "htmlfile: Unspecified error." exception. I can resolve this problem in the jQuery library by replacing elem.offsetParent with calls to this function that I wrote: function IESafeOffsetParent(elem) { try { return elem.offsetParent; } catch(e) { return document.body; } } I also have to avoid calls to elem.getBoundingClientRect() as it throws the same error. For those interested, I only had to make these changes in the jQuery.fn.offset function in the Dimensions Plugin. My questions are: Although this works, are there better ways (cleaner; better performance; without having to modify the jQuery library) to solve this problem? If not, what's the best way to manage keeping my changes in sync when I update the jQuery libraries in the future? For, example can I extend the library somewhere other than just inline in the files that I download from the jQuery website. Update: @some It's not publicly accessible, but I will see if SO will let me post the relevant code into this answer. Just create an ASP.NET Web Application (name it DragAndDrop) and create these files. Don't forget to set Complex.aspx as your start page. You'll also need to download the jQuery UI drag and drop plug in as well as jQuery core Complex.aspx <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Complex.aspx.cs" Inherits="DragAndDrop.Complex" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head runat="server"> <title>Untitled Page</title> <script src="jquery-1.2.6.min.js" type="text/javascript"></script> <script src="jquery-ui-personalized-1.5.3.min.js" type="text/javascript"></script> <script type="text/javascript"> function initDragging() { $(".person").draggable({helper:'clone'}); $("#trashcan").droppable({ accept: '.person', tolerance: 'pointer', hoverClass: 'trashcan-hover', activeClass: 'trashcan-active', drop: onTrashCanned }); } $(document).ready(function(){ initDragging(); var prm = Sys.WebForms.PageRequestManager.getInstance(); prm.add_endRequest(function() { initDragging(); }); }); function onTrashCanned(e,ui) { var id = $('input[id$=hidID]', ui.draggable).val(); if (id != undefined) { $('#hidTrashcanID').val(id); __doPostBack('btnTrashcan',''); } } </script> </head> <body> <form id="form1" runat="server"> <asp:ScriptManager ID="ScriptManager1" runat="server"> </asp:ScriptManager> <div> <asp:UpdatePanel ID="updContent" runat="server" UpdateMode="Always"> <ContentTemplate> <asp:LinkButton ID="btnTrashcan" Text="trashcan" runat="server" CommandName="trashcan" onclick="btnTrashcan_Click" style="display:none;"></asp:LinkButton> <input type="hidden" id="hidTrashcanID" runat="server" /> <asp:Button ID="Button1" runat="server" Text="Save" onclick="Button1_Click" /> <table> <tr> <td style="width: 300px;"> <asp:DataList ID="lstAllPeople" runat="server" DataSourceID="odsAllPeople" DataKeyField="ID"> <ItemTemplate> <div class="person"> <asp:HiddenField ID="hidID" runat="server" Value='<%# Eval("ID") %>' /> Name: <asp:Label ID="lblName" runat="server" Text='<%# Eval("Name") %>' /> <br /> <br /> </div> </ItemTemplate> </asp:DataList> <asp:ObjectDataSource ID="odsAllPeople" runat="server" SelectMethod="SelectAllPeople" TypeName="DragAndDrop.Complex+DataAccess" onselecting="odsAllPeople_Selecting"> <SelectParameters> <asp:Parameter Name="filter" Type="Object" /> </SelectParameters> </asp:ObjectDataSource> </td> <td style="width: 300px;vertical-align:top;"> <div id="trashcan"> drop here to delete </div> <asp:DataList ID="lstPeopleToDelete" runat="server" DataSourceID="odsPeopleToDelete"> <ItemTemplate> ID: <asp:Label ID="IDLabel" runat="server" Text='<%# Eval("ID") %>' /> <br /> Name: <asp:Label ID="NameLabel" runat="server" Text='<%# Eval("Name") %>' /> <br /> <br /> </ItemTemplate> </asp:DataList> <asp:ObjectDataSource ID="odsPeopleToDelete" runat="server" onselecting="odsPeopleToDelete_Selecting" SelectMethod="GetDeleteList" TypeName="DragAndDrop.Complex+DataAccess"> <SelectParameters> <asp:Parameter Name="list" Type="Object" /> </SelectParameters> </asp:ObjectDataSource> </td> </tr> </table> </ContentTemplate> </asp:UpdatePanel> </div> </form> </body> </html> Complex.aspx.cs namespace DragAndDrop { public partial class Complex : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { } protected List<int> DeleteList { get { if (ViewState["dl"] == null) { List<int> dl = new List<int>(); ViewState["dl"] = dl; return dl; } else { return (List<int>)ViewState["dl"]; } } } public class DataAccess { public IEnumerable<Person> SelectAllPeople(IEnumerable<int> filter) { return Database.SelectAll().Where(p => !filter.Contains(p.ID)); } public IEnumerable<Person> GetDeleteList(IEnumerable<int> list) { return Database.SelectAll().Where(p => list.Contains(p.ID)); } } protected void odsAllPeople_Selecting(object sender, ObjectDataSourceSelectingEventArgs e) { e.InputParameters["filter"] = this.DeleteList; } protected void odsPeopleToDelete_Selecting(object sender, ObjectDataSourceSelectingEventArgs e) { e.InputParameters["list"] = this.DeleteList; } protected void Button1_Click(object sender, EventArgs e) { foreach (int id in DeleteList) { Database.DeletePerson(id); } DeleteList.Clear(); lstAllPeople.DataBind(); lstPeopleToDelete.DataBind(); } protected void btnTrashcan_Click(object sender, EventArgs e) { int id = int.Parse(hidTrashcanID.Value); DeleteList.Add(id); lstAllPeople.DataBind(); lstPeopleToDelete.DataBind(); } } } Database.cs namespace DragAndDrop { public static class Database { private static Dictionary<int, Person> _people = new Dictionary<int,Person>(); static Database() { Person[] people = new Person[] { new Person("Chad") , new Person("Carrie") , new Person("Richard") , new Person("Ron") }; foreach (Person p in people) { _people.Add(p.ID, p); } } public static IEnumerable<Person> SelectAll() { return _people.Values; } public static void DeletePerson(int id) { if (_people.ContainsKey(id)) { _people.Remove(id); } } public static Person CreatePerson(string name) { Person p = new Person(name); _people.Add(p.ID, p); return p; } } public class Person { private static int _curID = 1; public int ID { get; set; } public string Name { get; set; } public Person() { ID = _curID++; } public Person(string name) : this() { Name = name; } } }

    Read the article

  • "'data(...).options' is null or not an object" in jquery-ui

    - by ripper234
    I'm using jquery-ui 1.8, and getting this error in Internet Explorer: Webpage error details User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E) Timestamp: Mon, 10 May 2010 06:26:48 UTC Message: 'data(...).options' is null or not an object Line: 75 Char: 13074 Code: 0 URI: http://localhost:58365/Scripts/Lib/jquery-ui-1.8.custom.min.js Is this a known bug? Is there a workaround? The error happens when I use droppable/draggable.

    Read the article

  • jquery ui get id of child element of dragged element, when dropped

    - by Catfish
    I've read through many of the drag and drop threads on SO and i haven't found one that tells me how to get the child element id of the dragged element, when the dragged element is dropped. For example if you have <div id='drag'> <img id="something"/>//how do i get this id when #drag is dropped? </div> <div id='drop'> </div> and the js $('#drag').draggable({ containment: '#content', scrollSensitivity: 60, revert: 'invalid', cursor: 'move' }); $('#drop').droppable({ accept: '#albumImgs li', activeClass: 'dropContainerOpen', drop: function(event, ui) { var fileName = $(ui.draggable.attr('alt')); console.log(fileName); } });

    Read the article

  • JQuery UI Drop Disable on selected elements

    - by Suneth Kalhara
    i want to add drop limit on circles, i wrote a scrit for dragging circles the problem is user can drop circle on another circle, i don't want to allow it, simply i need to revert if the user drag and drop circle on another circle. i write some codes for this. but this not working for me, it always revert the dropped circle. here is my example url http://webxtreams.net/demoprofiles004/circledragger.html here is js code i run on fire bug $(".circle").draggable({ revert: 'invalid' }); $(".circle").droppable({ accept: function(el) { return el.hasClass('.circle'); } }); please help me to do that. have another little question - can we track the reverting event on this, i need to repaint the lines when reverting the circle :)

    Read the article

  • is it possible to mix DHTML and Applet for Drag and drop?

    - by indra
    I am working on some example to find if a Div (DHTML) on to Java Applet in a web page. I used YUI JS Drag drop library to make the div as droppable item and made the div surrounding the Applet as Drop Target. When I dropped it in the Div containing Applet, I am Calling some method in the applet from Javascript Drop handler? This is fine, but I have the problem if the applet contains different objects and regions , how to identify which object it is dropped on? is there any other approach to work with DHTML and applets for Drag and Drop? Also, is it possible to write DD between two applets? Thanks in advance.

    Read the article

  • jQuery Drag and Drop Checking Question

    - by Kim
    i am new to using jQuery and I just want to know how I can check whether a draggable object has been removed from the droppable object. Example, i have a dog and I dragged it to a doghouse which has a lightbulb that will light up indicating that the dog is there. When i drag the dog out of the doghouse, the lightbulb should go off again indicating the dog's absence. Help me please coz I really don't have any idea how to do this. Thanks in advance. :)

    Read the article

< Previous Page | 1 2 3 4  | Next Page >