How can I determine which events are associated with a DOM element?

When using the Wordpress visual editor, if you have a short code [gallery], in visual mode it is displayed with a placeholder.

By clicking on the placeholder, you will overlay two icons - edit the gallery and delete the gallery.

I’m trying to figure out which function is triggered when I click “Edit Gallery”.

The button is an image with a domain identifier wp_editgallery, and it looks like this:

screenshot-with-shadow.png

My instinct is to check the item using the Chrome web inspector:

After finding the element, I check the properties panel and look for events, but the results are somewhat mysterious:

screenshot-with-shadow.png

So far I have tried the above method as well:

var events = jQuery._data('#wp_editgallery', 'events');

, DOM? Visual Event, , - .

, javascript DOM?

+5
1

. Chrome! , DOM. !

-1

All Articles