• Resolved billysgtr

    (@billysgtr)


    Hi,
    I am trying to save a lessons from front-end(I use Front End Course Creation for LearnDash) and I am getting the following warnings:

    Warning: Illegal string offset ‘sfwd-lessons_course’ in …/wp-content/plugins/buddypress-learndash/includes/bp-learndash-loader.php on line 83

    Warning: Cannot modify header information – headers already sent by (output started at …/wp-content/plugins/buddypress-learndash/includes/bp-learndash-loader.php:83) in …/wp-includes/pluggable.php on line 1167

    Lessons saved on back-end but I am getting this warning page. How can I fix that?

    Thank you in advance for your help

    https://www.ads-software.com/plugins/buddypress-learndash/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter billysgtr

    (@billysgtr)

    Sorry bothering you again but it is vital to fix that. Do have any suggestions?

    Thanks

    Plugin Author BuddyBoss

    (@buddyboss)

    Hi billysgtr
    We’ve been working on a patch to solve the issue, but we still need to test it before it’s included in a future version.

    If you feel comfortable editing PHP files, you can test the patch yourself by making the changes highlighted here.

    Open file for edit at path /plugins/buddypress-learndash/includes/bp-learndash-loader.php and replace line #81 to #83 with next lines.

    // return if this lesson is not attached to a course still
     $course_id = get_post_meta( $lesson_id, 'course_id', true );
    
     //fallback check into a lesson _sfwd-lessons meta
     if ( empty( $course_id ) ) {
     $course_id_obj = get_post_meta( $lesson_id, '_sfwd-lessons', true );
     $course_id = isset( $course_id_obj['sfwd-lessons_course'] ) ? $course_id_obj['sfwd-lessons_course'] : '0';
     }

    Let me know how it goes.

    Thread Starter billysgtr

    (@billysgtr)

    Hi,

    Thank you very much for the answer.

    I tested the patch and it worked! This is great!

    Thanks!

    Plugin Author BuddyBoss

    (@buddyboss)

    Cool

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Warnings’ is closed to new replies.