Created
September 10, 2016 07:44
-
-
Save jerome-diver/d1505c26309819975d89a2cfe74970ab to your computer and use it in GitHub Desktop.
why rails-4 application doesn't care about delegate event for bind ajax ckeditor each time ?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// try it... but after the first call and cancel, the second call show that it serve nothing... | |
$(document).on('click', 'form[data-remote]', function(){ | |
for (instance in CKEDITOR.instances){ | |
CKEDITOR.instances[instance].updateElement(); } }); | |
// try this... still doesn't change, still failed to load ckeditor on second call AJAX edition | |
$(document).on('ajax:before', 'form[data-remote]', function(){ | |
for (instance in CKEDITOR.instances){ | |
CKEDITOR.instances[instance].updateElement(); } }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment