LLMS_View_Manager::modify_enrollment_status( string $status )
Modify the enrollment status of current user based on the view.
Description Description
Students will always show as enrolled.
Visitors will always show as not-enrolled.
Parameters Parameters
- $status
-
(string) (Required) The actual status for the current user.
Return Return
(string)
Source Source
File: includes/class.llms.view.manager.php
public function modify_enrollment_status( $status ) {
switch ( $this->get_view() ) {
case 'visitor':
$status = false;
break;
case 'student':
$status = 'enrolled';
break;
}
return $status;
}
Expand full source code Collapse full source code View on GitHub
Changelog Changelog
| Version | Description |
|---|---|
| 3.7.0 | Introduced. |