Class Sensei_Lesson
Sensei Lessons Class
All functionality pertaining to the lessons post type in Sensei.
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
integer
|
|
public
integer|boolean
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
#
quiz_panel_question( $question_type = '', $question_counter = 0, $question_id = 0, $context = 'quiz', $multiple_data = array() )
|
public
|
|
public
|
#
quiz_panel_get_existing_questions( $question_status = 'all', $question_type = '', $question_category = '', $question_search = '', $page = 1 )
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
array
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
integer|boolean
|
|
public
array
|
|
public
integer
|
|
public
integer
|
#
lesson_quizzes( integer $lesson_id = 0, string $post_status = 'any', string $fields = 'ids' )
lesson_quizzes function. |
public
array
|
#
lesson_quiz_questions( integer $quiz_id = 0, string $post_status = 'any', string $orderby = 'meta_value_num title', string $order = 'ASC' )
Fetches all the questions for a quiz depending on certain conditions. |
public
|
|
public
string
|
#
lesson_image( integer $lesson_id = 0, string $width = '100', string $height = '100', $widget = false )
lesson_image function. |
public static
|
|
public static
string
|
#
lesson_excerpt( WP_Post $lesson = null, boolean $add_p_tags = true )
Returns the the lesson excerpt. |
public
integer|boolean
|
|
public
|
#
all_lessons_edit_fields( string $column_name, string $post_type )
Add the admin all lessons screen edit options. |
public
string
|
#
generate_all_lessons_edit_field( string $title, string $field )
Create the html for the edit field |
public
|
#
save_all_lessons_edit_fields( )
Respond to the ajax call from the bulk edit save function. This comes from the admin all lesson screen. |
public
|
|
public static
array
|
#
single_course_lessons_classes( array $classes )
Filter the classes for lessons on the single course page. |
public static
|
|
public static
|
|
public static
string
|
|
public static
mixed
|
#
get_lesson_prerequisite_id( $current_lesson_id )
Returns the lesson prerequisite for the given lesson id. |
public static
boolean
|
#
is_prerequisite_complete( $lesson_id, $user_id )
This function requires that you pass in the lesson you would like to check for a pre-requisite and not the pre-requisite. It will check if the lesson has a pre-requiste and then check if it is completed. |
public static
|
|
public static
|
|
public static
|
#
prerequisite_complete_message( )
Show a message telling the user to complete the previous message if they haven't done so yet |
public static
|
#
deprecate_sensei_lesson_archive_header_hook( )
Deprecate the sensei_lesson_archive_header hook but keep it active for backwards compatibility. |
public
|
|
public static
|
|
public static
|
|
public static
|
#
footer_quiz_call_to_action( integer $lesson_id = 0, integer $user_id = 0 )
Output the quiz specific buttons and messaging on the single lesson page |
public static
|
|
public static
|
#
user_lesson_quiz_status_message( integer $lesson_id = 0, integer $user_id = 0 )
Display the leeson quiz status if it should be shown |
public static
string
|
#
limit_archive_content( $content )
On the lesson archive limit the number of words the show up if the access settings are enabled |
public static
array
|
public
|
$token
|
|
public
|
$meta_fields
|