jquery - execute command when droppable target is filled with item -


i'm trying to: http://jsfiddle.net/2phuw/12/

if ( //if target filled items) {  //dosomething } 

but can't logic work out.

try this:- running alert if gets filled up.

i checking condition here see if slots filled in.

$('.ui-droppable').find('span.closer').length == $('.ui-droppable').length     if ($('.ui-droppable').find('span.closer').length == $('.ui-droppable').length) {      alert('listo ahora puedes simularlo');      //if target filled      $(".status1").replacewith('<i class="icon-check"></i> listo ahora puedes simularlo'); //update status       //put composition params    } else {         $(".status1").replacewith('<i class="icon-edit"></i> sigue');    } 

demo


Comments

Popular posts from this blog

php - cannot display multiple markers in google maps v3 from traceroute result -

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -