Namaste! LMS Help & How-To

For even more comprehensive documentation check our new documentation and demo site!

Namaste! LMS has a set of powerful shortcodes that let you output parts of the LMS contents or reports in places of your choices. The context-dependent shortcodes are explained directly on the screens where you can copy them. The others are documented in the internal Help page of the plugin and also here:

Available Shortcodes

This is flexible shortcode that can be placed inside a lesson or course content. It will display what the logged in student still needs to do to complete the given lesson or course. You can pass "ul" or "ol" as first argument to define ordered or unordered list.

displays enroll button or "enrolled/pending enrollment" message in the course. The shortcode accepts argument course_id to specify course ID outside of the course page. You can also pass parameters free_button_text and paid_button_text to specify the text to be shown for the enroll buttons. The first one is used when the student can enroll for free, and the second one - when they have to pay a fee.

Displays simplified version of the student dashboard - the same table with all the available courses but without the "view lessons" link. Instead of this link you can include the shortcode for "lessons in course" (given below) in the course page itself.
You can pass the attribute enrolled=1 to limit this page to displaying courses the user has enrolled to. Note that it will display even courses with pending or rejected enrollment, frozen access, and completed courses

Displays the "My certificates" page.

Displays links to the certificates earned by the currently logged user in the course. This works for the current course when placed in a course page. You can also use the shortcode by passing parameter "course_id" like this: [namaste-earned-certificates course_id=5]. You can also add some text which will be conditionally displayed where there are any certificates earned. For example: [namaste-earned-certificates course_id=5 text="You have earned certificates for completing this course:"]

or or will display all the lessons in a course along with links to them. If you use the second format and pass "status" as first argument, the shortcode will output the lessons in a table where the second argument will be the current status (started, not started, completed). You can also pass a number in place of the argument "y" to specify a course ID (otherwise current course ID is used). This might be useful if you are manually or programmatically creating some list of courses along with the lessons in them. If you want to use the course ID argument but not the status columng, pass 0 in pace of status like this: [namaste-course-lesson 0 5]. The third format lets you specify ordering using SQL field names from the posts table. For example [namaste-course-lessons 0 0 post_date DESC] will return the lessons displayed by the order of publishing, descending (latest lesson will be shown on top). In place of "list_tag" you can pass "ul" or "ol". If empty, defaults to "ul". Note that status column will be shown only for logged in users.

The named argument show_excerpts can be used to show the post excerpts like this: show_excerpts=1. Example: [namaste-course-lessons 0 0 post_date DESC show_excerpts=1]

If you use a grading system, the named argument show_grade can be used to show the grade given to the lesson like this: show_grade=1. Example: [namaste-course-lessons status show_grade=1]. It will work only when "status" is passed.

Confused?! Follow the link to the shortcode generator inside the Help page in your Namaste! LMS menu.

or can be used only in a course page and will display the first lesson from the course. You can replace "hyperlinked text" with your own text. If you omit the parameter the link will say "first lesson".

or [namaste-next-lesson "hyperlinked text"] can be used only in a lesson and will display the next lesson from the course. You can replace "hyperlinked text" with your own text. If you omit the parameter the link will use the lesson title as hyperlinked text.

or [namaste-prev-lesson "hyperlinked text"] Similar to the above, used to display a link for the previous lesson in this course. Note that lessons are ordered in the order of creation.

(where X is lesson ID) will output the assignments to the lesson on the front-end. The links to submit and view solutions will also work. You can omit the "lesson_id" parameter and pass it as URL variable. This could be useful if you are manually building a page with lessons and want to give links to assignments from it.

Generates a search form for searching in courses and lessons. Non logged in users or users not enrolled in courses can search only within the course contents. When user is enrolled in a course, the search also searches in lessons and let them restrict to a specific lesson.

Displays the total number of available (published) courses on the site.

Displays the total number of students enrolled in courses on the site. Add the attribute course_id=X to show the number of students enrolled in a given course (replace X with the course ID).

Displays the total number of assignmentson the site. Add the attribute course_id=X to show the number of assignments in a given course (replace X with the course ID) and lesson_id=X to show the number of assignments in a given lesson (replace X with the lesson ID).

Displays data from user profile. The "field" parameter should contain a field name from the WP users or usermeta table. The parameter "default" sets what to display if the user is not logged in or the data is empty. You can also pass attribute "user_id" to specify user other than the currently logged in user.

Shortcodes enabled by using points system

  1. and (where "x" is given user ID) outputs the total number of points the user has earned.
  2. and displays a leaderboard based on collected points. Replace "x" with the number of users you want to show. When you use the second shortcode the usernames will be shown in a table with the points collected in front of them.