2009-12-25 12:40:21 -05:00
|
|
|
var activeRequests = 0;
|
|
|
|
$(function() {
|
|
|
|
$('#change').text('I changed it');
|
|
|
|
$('#drag').draggable();
|
|
|
|
$('#drop').droppable({
|
|
|
|
drop: function(event, ui) {
|
|
|
|
ui.draggable.remove();
|
|
|
|
$(this).html('Dropped!');
|
|
|
|
}
|
|
|
|
});
|
|
|
|
$('#clickable').click(function() {
|
|
|
|
var link = $(this);
|
|
|
|
setTimeout(function() {
|
|
|
|
$(link).after('<a href="#">Has been clicked</a>');
|
|
|
|
$(link).after('<input type="submit" value="New Here">');
|
|
|
|
$(link).after('<input type="text" id="new_field">');
|
2010-01-01 13:36:45 -05:00
|
|
|
$('#change').remove();
|
2009-12-25 12:40:21 -05:00
|
|
|
}, 500);
|
|
|
|
return false;
|
|
|
|
});
|
|
|
|
$('#waiter').change(function() {
|
|
|
|
activeRequests = 1;
|
|
|
|
setTimeout(function() {
|
|
|
|
activeRequests = 0;
|
|
|
|
}, 500);
|
|
|
|
});
|
2010-02-15 08:54:11 -05:00
|
|
|
$('#with_focus_event').focus(function() {
|
|
|
|
$('body').append('<p id="focus_event_triggered">Focus Event triggered</p>')
|
|
|
|
});
|
2010-02-27 13:27:06 -05:00
|
|
|
$('#checkbox_with_event').click(function() {
|
|
|
|
$('body').append('<p id="checkbox_event_triggered">Checkbox event triggered</p>')
|
|
|
|
});
|
|
|
|
});
|