• Resolved NeilAtw

    (@neilatw)


    Hello developers,
    Thank you so much for this plugin, we are using it as part of our LearnDash courses, and would be lost without it.

    But I would love to know how we can reset the results data for the H5P modules.
    When we are developing new courses, we build H5P modules and test them extensively. It would be great if we can reset all usage/result information for an individual user.

    If it’s not possible any other way, can you tell me the db table(s) I can empty for a given user?

    Many thanks.

    Neil A.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author icc0rz

    (@icc0rz)

    Unfortunately, there is no interface for doing this, yet. Hopefully, there will be soon as I see more and more people requesting it.

    You can delete results manually through the wp_h5p_results table. Remember to update the database prefix if you’re using something other than wp_.

    Example 1:
    DELETE FROM wp_h5p_results WHERE user_id = 0;

    You can get the user_id from the interface/urls or the wp_users table.

    Example 2, delete by email:
    DELETE FROM wp_h5p_results WHERE user_id = (SELECT ID FROM wp_users WHERE user_email='[email protected]');

    You can also reset all results for a specific content, example 3:
    DELETE FROM wp_h5p_results WHERE content_id = 0;

    Or both, example 4:
    DELETE FROM wp_h5p_results WHERE content_id = 0 AND user_id = 0;

    I hope this will be useful to you.

    Thread Starter NeilAtw

    (@neilatw)

    Thanks so much!
    That’s a great help.

    Look forward to seeing it available in the interface soon. ??

    Neil

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Resetting H5P data’ is closed to new replies.