Last active
August 29, 2015 13:57
-
-
Save rockschtar/9588721 to your computer and use it in GitHub Desktop.
WordPress: Hook into Widget save Javascript Callback
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
jQuery(document).ajaxSuccess(function(e, xhr, settings) { | |
var widget_id_base = 'my-widget-id-base'; | |
if(settings.data && settings.data.search('action=save-widget') != -1 && settings.data.search('id_base=' + widget_id_base) != -1) { | |
//do something | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment