Content - Drag the Words not working correctly

Hi,

We are trying to use a Drag the Words H5P quize inside Opigon on Drupal but although it works when we preview the quiz, when we try it from the lesson itself the drag works, but we are unable to reposition an already placed answer, which we can do in the preview area. Also we have ticked the behaviour config box to allow the solution to be shown and also to enable retry at the end of the quiz, but again, this doesn't work in the published lesson but does work in the preview.

What's likely to be going wrong?

The Drag Text version is apparently 1.5.7

Drupal is version 7.56

Opigno version 7.x.1.26

Thanks.

M

BV52's picture

Hi M,

Is it possible to attach the H5P here (less than 16 MB) so that we can look at the settings. I am thinking that there could be a setting that just needs to be tweaked to get it working.

-BV52

Hi,

I'm not sure how to get the H5P code to upload here. When I try and use the Download button on the page containing my H5P Drag text issue I get an access denied page even though I'm logged in to the Drupal site as the administrator! Is there another way of getting what you're looking for?

Thanks

I have what I believe is the h5p file you asked for. Hopefully it will shed some light on why it's not working fully.

Thanks

icc's picture

Hi, 

Drupal's Quiz module overrides/controls the behavior of the retry and show solutions buttons when the quiz is being taken. Retry is always disabled and Show solutions depend on the Quiz's feedback options. 

Hi icc

Thanks for the info. I have been able to get the solutions showing by changing somw setting related to the quiz module. 

Do you also think that the quiz module is also stopping the ability to drag an incorrect answer to a different location until you find the correct location, I think this is using the Instant feedback option in the H5P quiz?

Thanks.

thomasmars's picture

Hi Dayfold,

Indeed this seems to be the case. I tried your Drag Text as a standalone H5P, where it worked fine, but inside Drupal Quiz it does not work properly with the instant feedback option enabled.

I have create an issue for this in the public issue tracker: https://h5ptechnology.atlassian.net/browse/HFP-1353, however I'm uncertain if this will be prioritized since it is a quite rare combination of settings. We are always open for pull requests though.

Thanks for the feedback.

I am getting similar errors reported in Chrome and IE. The Drag Word content created in Wordpress is not showing in preview or when browsing my site. Here are the errors:

Error report from H5P:

23ee0ceefcd2648ad0aa841dcb4a3cadb6f240c2d.js Failed to load resource: the server responded with a status of 403 (Forbidden)

h5p.js?ver=1.8.4:843 

Unable to find constructor for: H5P.DragText 1.5

 

H5P.error @ h5p.js?ver=1.8.4:843

h5p.js?ver=1.8.4:963 Uncaught TypeError: Cannot read property 'getCopyrights' of undefined

    at Object.H5P.getCopyrights (h5p.js?ver=1.8.4:963)

    at HTMLDivElement.<anonymous> (h5p.js?ver=1.8.4:149)

    

at Function.each (jquery.js?ver=1.8.4:2)

    

at init.each (jquery.js?ver=1.8.4:2)

    

at Object.H5P.init (h5p.js?ver=1.8.4:92)

    

at HTMLDocument.<anonymous> (h5p.js?ver=1.8.4:2129)

    

at c (jquery.js?ver=1.8.4:2)

    

at Object.fireWith [as resolveWith] (jquery.js?ver=1.8.4:2)

    

at Function.ready (jquery.js?ver=1.8.4:2)

    

at HTMLDocument.H (jquery.js?ver=1.8.4:

thomasmars's picture

Hi,

The key statement here is "23ee0ceefcd2648ad0aa841dcb4a3cadb6f240c2d.js Failed to load resource: the server responded with a status of 403 (Forbidden)". This means your server is not configured to allow you to view the given file. The file is a concatenated, cached file of all your JavaScript.

This should be possible to resolve by figuring out exactly what address the "23ee0ceefcd2648ad0aa841dcb4a3cadb6f240c2d.js" has (this can be found in the network tab of your browser developer tools). Then you must find the file on your server file system and configure your server to allow it to serve files from that location. If you're using Apache, see their mapping urls to files guide. After you've done this, check that you can access the file through the address, and then try to see if the H5P will display now.

Thank you Thomas. I have found the folder (uploads/h5p/cachedassets) where the above cached file is and there is a htaccess file there which prvents execution of Javascript. The /js setting has now been removed but my provider advised me to try and move the H5P assets elsewhere as this folder is not for js files. I don't know how to do this>

fnoks's picture

This has been answered here: https://h5p.org/comment/14601#comment-14601