Hi there, i have a pretty beginner question:
i would like to combine a login function and a email-sending function in one controller, and when i do that, only one function works (the top one).
So, how can i have 2 function in one controller? they are combined or chained, but should be called seperately.
this here doesn’t seem to work:
<?php
return function ($kirby) {
if ($kirby->user()) {
}
[...]
};
return function($kirby, $pages, $page) {
if($kirby->request()->is('POST') && get('submit')) {
[...]
}
];
};