Developers

Technical forum about Content Type or System Plugin development.
Here you can apply for developer access.

Attaching a javascript file on H5P pages in a custom module in drupal 8

Forums: 

I am creating a new module in which a have a js which i want to integrate on pages which have h5p content. At present I am using the hook element info alter as follows

function memodule_element_info_alter(array &$types)

      {

           if (isset($types['html']))

               { $types['html']['#attached']['library'][] = 'mymodule/mymodule';

H5P Video - Wordpress - Video Completion

Forums: 

I'm usisng the video-interaction with wordpress. I use Vimeo for my videos.

Everything is working fine.

However, I would like to capture the video completion event, when the H5P video is ended. For example, Triggering to next module after 5 seconds when the video is completed. and mark unit as complete.

Something like this 

Status of H5P CLI development server

serettig's picture
Forums: 

Hi,

to speed up the development of my library a bit, I've tried the H5P CLI development server, but it's not running smoothly with my library (and others). The JavaScript code often complains about undefined objects in the editor, for example. I guess this is because the development server uses a core API  that are outdated. Would it be enough to replace the core API files with the current ones or are these modified version of the normal files?

Or is my problem with the server caused by something I did wrong when configuring it?

Pages