fixed beforeSend callback #63

Closed
wants to merge 2 commits into
from

8 participants

@jerrett

Currently the event beforeSend is triggered, but the code is listening for before meaning it never gets hit, and buttons get blanked out and broken when data-disable-with is used

@tomrossi7

Thank you so much!!!!

Thanks! It works!

Thanks jerrett -- Fixed up my disable_with issues. I'm curious: What does the ".rails" do in the event name given to live()?

@mislav
Ruby on Rails member

Hello, in fbbefa0 we had a little discussion and we're going to get to beforeSend issues soon, including your fix. Thanks

@iamvery

I am also quite interested in this. I was having issues with my beforeSend callback not being called, even when using your ajaxSetup method of "initializing" a global beforeSend callback. Anyway, take a look at this fork. Maybe d94dc1d4e3d4bed0cc2588c44a6ed6b5d6b3ac88 is helpful?

@mislav
Ruby on Rails member

It doesn't seem you are very confident about what you're doing here. Your "improvement" only seems to complicate things more, but you were right that original jQ "beforeSend" callback has two parameters.

We'll get to the bottom of this. Us maintainers have to have an internal chat

@iamvery

No worries, I think I haven't had time to fully understand the root issue at hand. I'm looking forward to seeing where this goes. Just trying to be helpful :P

@mislav
Ruby on Rails member

test that "ajax:beforeSend" bubbles and can cancel the ajax request

closed by 0ff66c4, #71, #73

@JangoSteve JangoSteve added a commit to JangoSteve/jquery-ujs that referenced this pull request Aug 13, 2012
@JangoSteve JangoSteve Modified form button click selector. Fixes #63. 33ce990
@JangoSteve
Ruby on Rails member

Oops, disregard that last commit, was meant to reference issue 63 jquery-rails.

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment