This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

Ilesyt
Ilesyt

Hello, as my title suggests, I am trying to extend the user plugin with a function.

I have checked https://octobercms.com/docs/plugin/extending And I have also tried implementing it, but I wasn't successful. Could anyone help me how to properly do this?

Ilesyt
Ilesyt

Lol, I posted this after scouring the site for 2 days.

But 6 mins after posting it, I found the solution: https://octobercms.com/docs/services/behaviors

This is pretty much it:

 $model->addDynamicMethod('getTest', function() use ($model) {
               /* this is where you write the function */
            return something;
 });

Last updated

1-2 of 2

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.