adrianmak Posted May 9, 2016 Share Posted May 9, 2016 There is a member template which has a checkbox approval field. When user login, this field will be checked. if true the login session will go ahead otherwise a message will display "your account is not approved yet". To approve a member, administrator will update this field at the pw backend admin ui. Something like that When a page saved, a email will send to the user to notify your account is approved. I add a page saved hook in /sites/ready.php But how could I get the admin form data ? /sites/ready.php function isMemberUserTemplate($tpl) { return ($tpl == 'member-user'); } $pages->addHookAfter("saved", function($event) { $page = $event->object; $is_MemberUser = isMemberUserTemplate($page->template); if ($is_MemberUser) { // how to get the admin form page approval field ? } }); Link to comment Share on other sites More sharing options...
arjen Posted May 9, 2016 Share Posted May 9, 2016 Checkout these and these lines. 5 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now