Execute function on button click at the panel (own field)



I created a new field with a button for the panel. Now I want that if the user is click on that button that a function is executed without changing the panel itself.
Which method from the basefield I have to use for that? The Method result()is executing on the save button.
I need this button not only on click on the save button.

Or is this only possible through an ajax request?



This field may already have what you need: https://github.com/bnomei/kirby-opener


If this plugin is not what you are looking for, please be more specific as to what your button is supposed to do.