dozent_instructor_approve( int $instructor_id )
Approve an instructor
Parameters
- $instructor_id
-
(int) (Required)
Source
File: includes/core-functions.php
function dozent_instructor_approve( $instructor_id = 0 ) { if ( ! $instructor_id ) { return; } do_action( 'dozent_approved_instructor_before', $instructor_id ); update_user_meta( $instructor_id, '_dozent_instructor', 'approved' ); $instructor = new WP_User( $instructor_id ); $instructor->add_role( DOZENT_INSTRUCTOR_ROLE ); do_action( 'dozent_approved_instructor_after', $instructor_id ); }
Changelog
Version | Description |
---|---|
DozentLMS 1.0.0 | Introduced. |