JQuery Drag and Drop Linking
<p>I am trying to make Jquery drag and drop app. I want to link each image to a droppable frame. I can't use IDs, so what is a better way to write it to check to see if they are the same?</p>

<p>EDIT: Here is the code</p>

<pre><code>function handleDropEvent( event, ui ) {
        var slotNumber = $(this).attr('id');
        var cardNumber = ui.draggable.attr('id');
        var draggable = ui.draggable;
        if ( slotNumber == cardNumber ) {
            alert("Match" + slotNumber + cardNumber)
            ui.draggable.draggable( 'disable' );
            $(this).droppable( 'disable' );
            ui.draggable.position( { of: $(this), my: 'left top', at: 'left top' } );
            ui.draggable.draggable( 'option', 'revert', false );}
      }
</code></pre>

<p>As you can see, I can use ID to link them, but supposedly that is an extremely bad way to do it. Does anyone have any ideas?</p>
