• I have two courses. One is displayed without a problem. The other is not. The one with the problem returns these errors, when attempting to display it in the frontend:

    Fatal error
    : Uncaught ValueError: Unknown format specifier “a” in /home/{{mysite}}/public_html/wp-content/plugins/tutor/templates/single/course/reviews.php:112
    Stack trace:
    #0 /home/{{mysite}}/public_html/wp-content/plugins/tutor/templates/single/course/reviews.php(112): printf(‘% avalia\xC3\xA7\xC3\xB5es’, ‘2’)
    #1 /home/{{mysite}}/public_html/wp-content/plugins/tutor/includes/tutor-template-functions.php(130): include(‘/home/…’)
    #2 /home/{{mysite}}/public_html/wp-content/plugins/tutor/includes/tutor-template-functions.php(1009): tutor_load_template(‘single.course.r…’)
    #3 /home/{{mysite}}/public_html/wp-content/plugins/tutor/templates/single-course.php(65): tutor_course_target_reviews_html()
    #4 /home/{{mysite}}/public_html/wp-includes/template-loader.php(106): include(‘/home/…’)
    #5 /home/{{mysite}}/public_html/wp-blog-header.php(19): require_once(‘/home/…’)
    #6 /home/{{mysite}}/public_html/index.php(17): require(‘/home/…’)
    #7 {main}
    thrown in
    /home/{{mysite}}/public_html/wp-content/plugins/tutor/templates/single/course/reviews.php
    on line
    112

    This prevents the page from being shown. How to resolve?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hi @mastababa,

    Could you please share the course URL or a screenshot of the issue so we can review it directly? Additionally, are you running Tutor LMS in a different language than English? Sometimes localization strings can cause unexpected behavior in templates like the reviews section.

    Looking forward to your response.

    Thread Starter Babak Fakhamzadeh

    (@mastababa)

    URL with problem: https://cursos.oeco.org.br/courses/introducao-ao-jornalismo-ambiental/

    Error reporting is turned on. You can inspect the source to see the error.

    Yes, the site runs in Portuguese.

    Hey @mastababa ,

    Thank you for sharing the course URL.

    Please try switching the site language to English and check if the issue still persists. If it works fine in English, then the issue is related to translation. You can fix it with the following steps:

    1. Change the site language back to Portuguese.
    2. Install and activate the Loco Translate plugin.
    3. Go to Loco Translate → Plugins → Tutor LMS.
    4. Create a new Portuguese translation (if not already available).
    5. Sync the file and save it.
    6. Search for the missing or incorrect translation strings (for example, the one that caused the error) and update them.
    7. Save the translation file and recheck the course page.

    This should resolve the string error on your course page.

    Thread Starter Babak Fakhamzadeh

    (@mastababa)

    Resolved. Thanks.

    Hey @mastababa ,

    You are welcome. Feel free to reach out to us again if you need any further assistance.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Unknown format specifier’ is closed to new replies.