LLMS_Lesson::get_sibling_section_query( string $direction )
Performs a query to retrieve sibling lessons from the lesson’s adjacent section
Description Description
This will retrieve either the first lesson from the course’s next section or the last lesson from the course’s previous section.
Parameters Parameters
- $direction
-
(Required) Direction of navigation. Accepts either "prev" or "next".
Return Return
(false|int) WP_Post ID of the sibling lesson or false
if one doesn't exist.
Source Source
File: includes/models/model.llms.lesson.php
Changelog Changelog
Version | Description |
---|---|
4.11.0 | Fix PHP Notice when trying to retrieve next lesson from an empty section. |
4.10.2 | Introduced. |