How can i get the Id of an Dragged Element and Bind while Dropping?
<p>Hi all how can i get the Id of on dragged element  and bind the id where i am dropping the element
here is what i am doing for my drag and drop</p>

<pre><code>        var i = 1;
       var z = 1;
       $(document).ready(function () {
           $("button[id='columnadd']").click(function () {
               // create the element
               var domElement = $('&lt;div id="shoppingCart' + i++ + '" class="shoppingCart"&gt;&lt;h2 class="ui-widget-header"&gt;Add Menu Items Here &lt;img src="../Images/delete.png" id="shoppingCart' + z++ + '" style="float: right; cursor:pointer;" onclick="removecolumn(this.id)"/&gt;&lt;/h2&gt;&lt;aside class="ui-widget-content" id="droppable"&gt;&lt;ol&gt;&lt;li class="placeholder"&gt;Add your items here&lt;/li&gt;&lt;/ol&gt;&lt;/aside&gt;&lt;/div&gt;');
               var holder = "#columnholder";
               $("#columnholder").append(domElement);
               //$(this).after(domElement);

               // at this point you have domElement in your page

               // make it droppable
               domElement.find("ol").droppable({
                   activeClass: "ui-state-default",
                   accept: '.small_box li',
                   greedy: true,
                   drop: function (event, ui) {                          
                       makeItDroppableToo(event, ui, this);                                             
                   }
               });
           });

           function makeItDroppableToo(e, ui, obj) {                  
               $(obj).find(".placeholder").remove();
               var id = this.id;
               alert(id);
               var placeholder = $("&lt;ol&gt;&lt;li&gt;Add Sub Menu here&lt;/li&gt;&lt;/ol&gt;");
               $("&lt;li&gt;&lt;/li&gt;").append('&lt;a  draggable="true" droppable=true&gt;' + ui.draggable.text() + '&lt;/a&gt;').append(placeholder).appendTo($(obj));

               // this is the same as the previous one
               placeholder.droppable({
                   greedy: true,
                   // put options here
                   drop: function (event, ui) {
                       makeItDroppableToo(event, ui, this);
                   }
               });
           }

           $(".small_box li" ).draggable({
               appendTo: "body",
               helper: "clone"
           });
       });
</code></pre>

<p>and this i my html from where i am dragging</p>

<pre><code>         &lt;div class="top-header"&gt;&lt;span class="heading"&gt;Menu Builder&lt;/span&gt;&lt;button id="preview" onclick="savemenu()" &gt;Save&lt;/button&gt;&lt;button id="columnadd" &gt;Add Column&lt;/button&gt;&lt;/div&gt;
&lt;div id="columnholder" class="column-holder"&gt;&lt;/div&gt;
&lt;div class="clear"&gt;&lt;/div&gt;
&lt;div class="menu-items"&gt;    
&lt;aside class="small_box"&gt;
     &lt;div class="menu-item-header"&gt;&lt;h4&gt;BRANDS&lt;/h4&gt;&lt;/div&gt;
      &lt;ul&gt;
             &lt;li id ="1"&gt;&lt;a id ="1001" class="" href="#"&gt;Brand1&lt;/a&gt;&lt;/li&gt;
            &lt;li id ="2"&gt;&lt;a id ="1002" href="#"&gt;Brand2&lt;/a&gt;&lt;/li&gt;
            &lt;li id ="3"&gt;&lt;a id ="1003" href="#"&gt;Brand3&lt;/a&gt;&lt;/li&gt;
            &lt;li id ="4"&gt;&lt;a id ="1004" href="#"&gt;Brand4&lt;/a&gt;&lt;/li&gt;
            &lt;li id ="5"&gt;&lt;a id ="1005" class="" href="#"&gt;Brand5&lt;/a&gt;&lt;/li&gt;
            &lt;li id ="6"&gt;&lt;a id ="1006" href="#"&gt;Brand6&lt;/a&gt;&lt;/li&gt;
            &lt;li id ="7"&gt;&lt;a id ="1007" href="#"&gt;Brand7&lt;/a&gt;&lt;/li&gt;
            &lt;li id ="8"&gt;&lt;a id ="1008" href="#"&gt;Brand8&lt;/a&gt;&lt;/li&gt;
     &lt;/ul&gt;
    &lt;/aside&gt;
</code></pre>

<p>here i will drag the element  when i do that i want to get the id and when i am bind the dragged element here</p>

<pre><code>           $("&lt;li&gt;&lt;/li&gt;").append('&lt;a  draggable="true" droppable=true&gt;' + ui.draggable.text() + '&lt;/a&gt;').append(placeholder).appendTo($(obj));
</code></pre>

<p>i want to bind that id to the  ,can any one tell me how can i do this</p>
