Can anyone tell me how I can write a function in accept condition and then how does it finds out that what to accept and what not to accept.
For example, I want to accept
According to the Jquery documentation on Selectors.
All draggables that match the selector will be accepted. If a function is specified, the function will be called for each draggable on the page (passed as the first argument to the function), to provide a custom filter. The function should return true if the draggable should be accepted.
Thus,
$('.selector').droppable({ accept: '.special' });
in their example will only act as if something has been dropped on it if it has the class 'special'. It looks like it can accept any Jquery selector.