How to trigger script execute after Save&Apply from LUCI page

In your init script, add:

service_triggers() {
    procd_add_reload_trigger example
}

This will execute an /etc/init.d/example reload when LuCI commits /etc/config/example.

As for the JSON menu items, you can find some info here:

See also the post below for a general overview over the request routing flow:

1 Like