Forum Replies Created

Viewing 15 replies - 436 through 450 (of 465 total)
  • Plugin Author icc0rz

    (@icc0rz)

    Hello!

    Unfortunately I haven’t gotten around to trying out the H5P xAPI plugin yet, but I’m guessing that is where the error messages are coming from. I would try asking in their support forum regarding these errors. If you have access and can look in your web server’s error log for further detail regarding the error messages, that would probably help.

    As for the Memory Game interaction we haven’t added the xAPI support yet. It’s on my list but I haven’t had the time yet. You should look for it in a future release. Be aware that content types like the Memory Game will not report score results like other exercises. There will only be duration and an extension which states the number of cards turns that were required.

    The wp_h5p_contents_user_data table keeps track of the current state for each content for each user when the Allow logged-in users to resume tasks option is enabled under Settings. E.g. when the users re-opens a presentation, it will open at the last slide the user was visiting. It will also keep track of what the user has answered on the tasks and etc.
    This is not a playback of xAPI and can not be directly viewed by the teacher or admin. It’s only there for users to be able to resume tasks.

    Plugin Author icc0rz

    (@icc0rz)

    Unfortunately, we didn’t manage to get them fixed in time for the release last week. However, we are aiming for another release very soon.

    I’m sorry for the inconvenience.

    Plugin Author icc0rz

    (@icc0rz)

    Hello! Currently, there’s an issue with the Save content state setting and the Course Presentation tool. It will be fixed in the upcoming release. Until then it’s best to disable the setting when using Course Presentation.
    We’re sorry for the inconvenience.

    Plugin Author icc0rz

    (@icc0rz)

    Hi! Actually the Iframe Embedder is created for easily display existing JavaScript applications like the PHET Simulations, which doesn’t require scrolling, or it uses internal scrolling. It automatically adjusts to the size of the frame which most normal web pages doesn’t do.

    Put I see your point and it could be useful to have an option for enabling scrolling. I’ve created a feature request on GitHub for it, but most likely it won’t be part of the release that’s coming shortly.

    Thank you for pointing this out.

    Plugin Author icc0rz

    (@icc0rz)

    Very good to hear! It’s fun to see people using and adapting the plugin to fit their needs ??

    Plugin Author icc0rz

    (@icc0rz)

    You must specify $deps. I don’t think the script needs to be registered. This should work:

    wp_enqueue_script('yourpluginslug-h5p-integration', plugins_url('yourplugin/scripts/h5p-integration.js'), array('h5p-jquery'), Your_Plugin::VERSION);

    Plugin Author icc0rz

    (@icc0rz)

    Yes, you must make sure script is loaded after the H5P scripts.

    Plugin Author icc0rz

    (@icc0rz)

    I’m sorry I think I misunderstood what you were trying to achieve. If you only want to insert a link that triggers your JavaScript, you won’t have to override the query class since you’ll only be modifying the UI, i.e. you won’t be adding any data.

    Unforently there aren’t many events/hooks into the data view table, so you’ll need to do something like this in a custom JavaScript:

    (function ($) {
      var pdfHandler = function (h5pContentId) {
        // Replace with code that opens your dialog etc.
        console.log('Opening dialog for H5P ' + h5pContentId);
      };
      var addedHeader = false;
    
      $(document).ajaxComplete(function(event, xhr, settings) {
        if (settings.url.indexOf('wp-admin/admin-ajax.php?action=h5p_contents') !== -1) {
          // Use setTimeout to run after AJAX
          setTimeout(function () {
            if (!addedHeader) {
              // Update headers
              $('#h5p-contents thead tr').append('<th class="h5p-edit-link"></th>');
              var $footTd = $('#h5p-contents tfoot td');
              $footTd.attr('colspan', parseInt($footTd.attr('colspan')) + 1);
              addedHeader = true;
            }
    
            // Add pdf button to each row
            $('#h5p-contents tbody tr').each(function () {
              var id = $(this).find('a:first').attr('href').match(/&id=(\d+)/)[1];
              $('<td/>', {
                'class': 'my-custom-pdf-button',
                tabIndex: 0,
                text: 'PDF',
                appendTo: this,
                on: {
                  click: function ()?{
                    pdfHandler(id);
                  },
                  keydown: function (event)?{
                    if (event.which === 32) {
                      pdfHandler(id);
                    }
                  }
                }
              });
            });
          }, 0);
        }
      });
    })(H5P.jQuery);

    You can also add the link by creating your own version of H5PContentAdmin::ajax_contents, but you’ll still need JS to activate it so it’ll be some more work.

    I hope this will be of some use to you or others looking to do the same.

    Plugin Author icc0rz

    (@icc0rz)

    Hi, this sounds exciting! Unfortunately, I don’t think there’s a simple way to do this. The table is created using JavaScript and uses AJAX to load data. You’ll want to add an SQL join to get the data you relate to the H5P content. To do this, you need to create your own class which extends the H5PContentQuery class. You’ll want to add the field to $this->fields and the table to $this->join. To use your new class you’ll have to add your own ajax callback to WP, i.e. your own version of H5PContentAdmin::ajax_contents. With the AJAX working and returning data you’ll simply have to change the URL and headers used by the JavaScript creating the table. This can be done my overriding the data in the H5PIntegration.dataViews array.

    And if you want even more control over the table you can always wp_dequeue_script the h5p/admin/scripts/h5p-data-views.js script and create your own version. Or override some of the functions in h5p/h5p-php-library/js/h5p-data-view.js.

    Plugin Author icc0rz

    (@icc0rz)

    What version of IE are you using? If you could open the debug console in IE (I think it’s F12) and look for any error messages, that would be of great help.

    You can try to change line 850 in h5p/admin/class-h5p-content-admin.php from:
    header('Content-type: application/json; charset=utf-8');
    to:
    header('Content-type: text/html; charset=utf-8');
    and see if it works.

    Plugin Author icc0rz

    (@icc0rz)

    You are absolutely correct! I’ve added a fix for the next version.

    Thanks!

    Plugin Author icc0rz

    (@icc0rz)

    The issues you’re having here is because of another issue. We’ll have this fixed in the next release. We’re sorry for the inconvenience.

    Thank you for reporting!

    Plugin Author icc0rz

    (@icc0rz)

    Thank you, this made it a lot easier to locate the issue. It seems there are some problems with the Italian translations, they haven’t been converted correctly from ISO-8859-1 to UTF-8. We will try repair them and have them ready for the next release early next week. I’m sorry for the inconvenience.

    Many thanks to you for pointing out this issue!

    Plugin Author icc0rz

    (@icc0rz)

    No feedback. Closing this issue.

    Plugin Author icc0rz

    (@icc0rz)

    Yes, but you’ll need to add the styling to the .h5p-button class your self.

    You can read more about adding the CSS file to all the content types at the Visual Changes page. We’re looking to add a text area in WordPress that makes it easier to add custom styles, but haven’t gotten around to it yet.

    Please note that the styling for the buttons will change in the next release of the content types, which is just around the corner. It will given the buttons a more unified look across all the content types.

Viewing 15 replies - 436 through 450 (of 465 total)