title: How to get the id of both the draggable and the droppable inside callback function
body: <p>I would like to drag and drop between the two  divs. 
  For this i am using the following javascript which works fine </p>
  
  <pre><code>var PortletDraggable = function () {
  
      return {
          //main function to initiate the module
          init: function () {
  
              if (!jQuery().sortable) {
                  return;
              }
  
              $("#sortable_portlets").sortable({
                  connectWith: ".portlet",
                  items: ".portlet", 
                  opacity: 0.8,
                  handle : '.portlet-title',
                  coneHelperSize: true,
                  placeholder: 'portlet-sortable-placeholder',
                  forcePlaceholderSize: true,
                  tolerance: "pointer",
                  helper: "clone",
                  tolerance: "pointer",
                  forcePlaceholderSize: !0,
                  helper: "clone",
                  cancel: ".portlet-sortable-empty, .portlet-fullscreen", // cancel dragging if portlet is in fullscreen mode
                  revert: 250, // animation in milliseconds
                  update: function(b, c) {
                      if (c.item.prev().hasClass("portlet-sortable-empty")) {
                          c.item.prev().before(c.item);
                      }   
                      alert('update called');
                     console.log('c'+c.item.index());
                  }
              });
          }
      };
  }();
  
  jQuery(document).ready(function() {
      PortletDraggable.init();
  });
  </code></pre>
  
  <p>And Whenever there is a drag drop happens there is a callback function by name  update which gets fired </p>
  
  <p>Is it possible to get the id of both the draggable and the droppable elements </p>
  
  <p><a href="https://jsfiddle.net/33keyjxx/14/" rel="nofollow">https://jsfiddle.net/33keyjxx/14/</a></p>
  
  <p>For example if i move <strong>cricket</strong> to fourth position the current position of cricket and its id also .</p>