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

dijo.dill
dijo.dill

Hi yall, I created a plugin using Builder Plugin, now I want to run PHP script once I click create in the create form. How to do it? I am a beginner will be great is anyone could give any simple solution. Thanks in advance.

daftspunky
daftspunky

Hello!

In your controller you can override these methods to run PHP code...

/**
 * formBeforeCreate is called before the creation form is saved
 * @param Model
 */
public function formBeforeCreate($model)
{
}

/**
 * formAfterCreate is called after the creation form is saved
 * @param Model
 */
public function formAfterCreate($model)
{
}

I hope this helps!

dijo.dill
dijo.dill

Thanks a lot. It really helped!!

1-3 of 3

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