@@ 463-467 (lines=5) @@ | ||
460 | $courses = get_posts( apply_filters( 'sensei_grading_filter_courses', $course_args ) ); |
|
461 | ||
462 | $html .= '<option value="">' . __( 'Select a course', 'woothemes-sensei' ) . '</option>'; |
|
463 | if ( count( $courses ) > 0 ) { |
|
464 | foreach ($courses as $course_id){ |
|
465 | $html .= '<option value="' . esc_attr( absint( $course_id ) ) . '" ' . selected( $course_id, $selected_course_id, false ) . '>' . esc_html( get_the_title( $course_id ) ) . '</option>' . "\n"; |
|
466 | } // End For Loop |
|
467 | } // End If Statement |
|
468 | ||
469 | return $html; |
|
470 | } // End lessons_drop_down_html() |
|
@@ 512-516 (lines=5) @@ | ||
509 | $lessons = get_posts( apply_filters( 'sensei_grading_filter_lessons', $lesson_args ) ); |
|
510 | ||
511 | $html .= '<option value="">' . __( 'Select a lesson', 'woothemes-sensei' ) . '</option>'; |
|
512 | if ( count( $lessons ) > 0 ) { |
|
513 | foreach ( $lessons as $lesson_id ){ |
|
514 | $html .= '<option value="' . esc_attr( absint( $lesson_id ) ) . '" ' . selected( $lesson_id, $selected_lesson_id, false ) . '>' . esc_html( get_the_title( $lesson_id ) ) . '</option>' . "\n"; |
|
515 | } // End For Loop |
|
516 | } // End If Statement |
|
517 | ||
518 | } // End If Statement |
|
519 |