I’ve got some basic code with jquery:
$.get("/booking.php", { event_id: event_id, time_id: time_id }, function(data) {
$('#booking_box_content').html(data);
});
Which works a treat. Thing is, i’d like to do something before the actual get command is sent. I know the above code is the shorthand, and I know how to do the longhand version with $.ajax() and beforeSend() – I guess i’m wondering if there is a way to do that with $.get()…
Not about get, but you might find another way of using beforeSend more convenient:
This would register beforeSend handler for all ajax requests made through jquery.