Recaptcha icon indicating copy to clipboard operation
Recaptcha copied to clipboard

Callback option needed

Open derekvasilich opened this issue 7 years ago • 4 comments

Added option for specifying attributes for the Helper i.e. to provide a callback function

derekvasilich avatar Oct 11 '18 16:10 derekvasilich

Any reason you can't specify the callback when loading component or the helper?

What you want can already be achieve using $this->loadComponent('Recaptcha.Recaptcha', ['callback' => 'foo']) or $this->viewBuilder()->setHelpers(['Recaptcha.Recaptcha' => ['callback' => 'foo']]).

ADmad avatar Oct 11 '18 17:10 ADmad

I don't see how that gets my data-callback attribute onto the view?

Or is what you're suggesting a way to get the attribute into the view, and so I would only need to commit the change to recaptcha view element?

derekvasilich avatar Oct 11 '18 17:10 derekvasilich

Ok. It works the way you suggested with no alterations to the Helper.

Not sure the advantage of having it this way though.

derekvasilich avatar Oct 11 '18 17:10 derekvasilich

Hi, what about the other callbacks? it would be useful to have an option for those too.

nachitox avatar Mar 11 '21 16:03 nachitox