Forum: Ruby on Rails RJS and :loading

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Hiroshi T. (Guest)
on 2005-12-28 03:44
(Received via mailing list)
Hi,

I'm a newbie with Ajax and RJS and have one basic question.

When contents in .rjs are exceuted in a Ajax sequence?

.rjs seems a kind of alternate for .rhtml view file, so I guess they are
in action after the controller action completed.
The contents of .rjs file are :complete scenario, right?

if so, can't  I write some on :loading action in .rjs?
like disabling submit-button.

TIA,

--
Hiroshi T. <removed_email_address@domain.invalid>
Rick O. (Guest)
on 2005-12-28 04:50
(Received via mailing list)
On 12/27/05, Hiroshi T. <removed_email_address@domain.invalid> wrote:
> if so, can't  I write some on :loading action in .rjs?
> like disabling submit-button.
>
> TIA,

Things like disabling the submit button should be handled on the
originating webpage with the :loading callback of link_to_remote or
form_remote_tag.  You are correct, the RJS is executed in the
:complete callback.

--
rick
http://techno-weenie.net
This topic is locked and can not be replied to.