WPLMS Quick Tips
Learn small, easy and fast tips for your WPLMS site. Simple less than 3 minute video tips.
Learn small, easy and fast tips for your WPLMS site. Simple less than 3 minute video tips.
How an Administrator can create an Instructor by changing the user role of a registered user from student to Instructor.
Adding Students to a course from the Administrator only settings panel without purchasing the course.
Learn how an Administrator can increase the subscription duration of a course for a particular student. The subscription duration to be increased should be pre-calculated in number of sections. example 1 day = 86400 seconds.
Learn how an Administrator can change marks for particular students for particular course.
Learn how an Administrator can assign badges for any course to any student on an ad-hoc basis, without the student appearing for the course.
Lean how an administrator can assign certificates to a student on an ad-hoc basis, without student taking the course.
You need to have the WPLMS Customizer plugin running and installed in your system.
Follow below steps to change the course menu :
add_filter('wplms_course_nav_menu',array($this,'wplms_course_nav_menu'));
function wplms_course_nav_menu($menu_array){
unset($menu_array['members']);
return $menu_array;
}
function wplms_course_nav_menu($menu_array){
$menu_array['external_link']=array(
'id' => 'external_link',
'label'=>__('My Custom Link','vibe'),
'action' => 'members', // Optional remove if you do not want to send any parameters
'link'=> 'http://www.mycustom-url.com'
);
return $menu_array;
}
You need to have the WPLMS Customizer plugin running and installed in your system.
Follow below steps to change the course menu :
function wplms_free_course_price($price_text){
$price_text= 'Livre';
return $price_text;
}
You need to have the WPLMS Customizer plugin running and installed in your system.
Follow below steps to change the course menu :
function wplms_unit_print_button($print_html){
return '';
}
You need to have the WPLMS Customizer plugin running and installed in your system.
A read more link is shown in the course description page, clicking on this button expands the remaining content of course description and a Less link appears. This tip shows how you can change the limit of the course description content shown before the read more link appears.
Follow below steps to change the read more limit in course description page :
add_filter('wplms_course_excerpt_limit',array($this,'wplms_course_excerpt_limit'),1,1);
Paste the below function at the end of the class:
function wplms_course_excerpt_limit($no){
$no= 120; // Set the limit in number of characters to be shown before the read more link {default: 1200}
return $no;
}
You need to have the WPLMS Customizer plugin running and installed in your system.
If you want to Hide the Badges and Certificates section in the Profile. You can control the visibility using some custom code.
Follow below steps to control the Certificates and Badges visibility :
add_action('bp_init',array($this,'manage_profile_snapshot'));
function manage_profile_snapshot(){
if(!bp_is_my_profile()) // Check if user Is viewing her own profile
remove_action('bp_before_profile_content','show_profile_snapshot');
}
function manage_profile_snapshot(){
if(!bp_is_my_profile() && !current_user_can('edit_posts')) // Check for Instructors and Administrators
remove_action('bp_before_profile_content','show_profile_snapshot');
}
Make sure Friendships is enabled in BuddyPress->Components
function manage_profile_snapshot(){
global $bp, $friends_template;
$friend_status = friends_check_friendship_status( $bp->loggedin_user->id, $bp->displayed_user->id );
if(!bp_is_my_profile() && !current_user_can('edit_posts') && $friend_status != 'is_friend') // Check for Instructors and Administrators
remove_action('bp_before_profile_content','show_profile_snapshot');
}
You can remove and place your custom content in place of the Become an Instructor button.
You need to have the WPLMS Customizer plugin running and installed in your system.
Follow below steps to remove and change the Instructor button.
add_action('bp_init',array($this,'wplms_remove_instructor_button')); // Removes the Become and Instructor Button
add_action('wplms_be_instructor_button',array($this,'wplms_be_instructor_button')); // Adds Extra function to run in place of Instructor button
/**
* Instructor Button Location
*/
function wplms_be_instructor_button(){
//Echo something to show in place of instructor button
//Example show a image banner
echo '<a href="#target_URL"><img src="#Target_IMAGE_SOURCE" alt="#TARGET_IMAGE_ALT" /></a>';
}
You need to have the WPLMS Customizer plugin running and installed in your system.
Follow below steps to change the course menu :
add_filters('vibe_thumb_featured_image',array($this,'vibe_thumb_heading'),1,2);
function vibe_thumb_featured_image($featured_html,$featured_style){
// Code to Add a Free label over courses
if($featured_style == 'course'){ // Just a validation check
$course_id=get_the_ID();
$free_course = false;
$free_course=get_post_meta($course_id,'vibe_course_free',true);
if(function_exists('vibe_validate') && vibe_validate($free_course)){
$featured_html .='FREE';
}
}
return $featured_html;
}