Basically the title. When I attempt to 'get' any activity to install and use in the editor of the H5P Interactive Content plugin the editor window disappears and nothing happens.
Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Same problem here. Here are the details:
Moodle 4.1.1 (Build: 20230116).
PHP 8.0.
H5P mod_hvp version 1.23.0 dated 2022121200 Additional plugin (the black icon).
H5P settings: Use H5P Hub mod_hvp | hub_is_enabled Yes
Add an activity or resource / Adding a new Interactive Content / Get (a content) / Install / Installing : nothing happens!
Browser Console says: TypeError: e.contentTypes is undefined
value https://MYMOODLESITE/mod/hvp/editor/scripts/h5p-hub-client.js?ver=2022121200:54 (etc.)
1.- On my Moodle site the core H5P mod_h5pactivity works fine, scheduled tasks retrieves h5p contents from the h5p hub OK.
2.- Using H5P mod_hvp Additional plugin (the black icon) I cannot retrieve H5P contents from the H5P hub, but of course I can still upload H5P contents created elswhere, which I use as a workaround, but this is still annoying and unexplainable.
Anyone else having this problem?
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
I will take a look at Lumi, thank you!
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
And Lumi is working too...
Maybe ver 4.1 broke something?
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
It could be that the cron task , that picksup contenttypes has not 'run' yet. I noticed this with new installations, since the task frequents is like 1 a month, when you have a new install it does not straight away 'downloads'/ 'make the contenttypes' avaiable.
If you are a site admin (or when not give them these instructions):
- Login to site
- Go to Server > scheduled task
- search for the task "Download available H5P content types from H5P.org (\core\task\h5p_get_content_types_task)
- if the column last run says "never' then click on the radar
- fill in at minute */1, the rest is *
- Save the changes
- Wait 1 to 5 minutes (it kind of depends on how frequently your cron is running)
- Refresh the page, check if column last run now has a data and time
- Click on the 'radar' again
- check thebox "Reset task schedule to default"
- Save changes
- Go to the COntent bank and check if you now see Contentypes.
If this did not work, check with your technical team/server contantperson if the Cron is correctly configured. Redo the steps.
I hope this fixed your issue.
Gemma
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
It looks like you have identified the error. None of the services have ever been run.
Moodle was installed automatically for me by the web hosting service I'm using. I'm going to open a ticket with them as I have Moodle knowledge but very little knowledge about managing a server especially when it comes to managing php files.
I'm just a team of one so hopefully I can get my head around it. Thank you!
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Installing content still doesn't work for the other H5P plugin however. But as long as I have a way not to create the content I'm happy!
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Why does Moodle wait so long to download this content?
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
When trying to download contents from the H5P hub I'm getting this error in the php_error.log:
[07-Feb-2023 16:42:36 Europe/London] Default exception handler: Exception - chmod(): Argument #1 ($filename) must be of type string, resource given Debug:
Error code: generalexceptionmessage
* line 247 of \mod\hvp\classes\framework.php: TypeError thrown
* line 247 of \mod\hvp\classes\framework.php: call to chmod()
* line 415 of \mod\hvp\editor\h5peditor-ajax.class.php: call to mod_hvp\framework->fetchExternalData()
* line 307 of \mod\hvp\editor\h5peditor-ajax.class.php: call to H5PEditorAjax->callHubEndpoint()
* line 133 of \mod\hvp\editor\h5peditor-ajax.class.php: call to H5PEditorAjax->libraryInstall()
* line 289 of \mod\hvp\ajax.php: call to H5PEditorAjax->action()
Any idea anyone?
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
i just uninstalled H5P (plugin - black icon) on 4.1 and reïnstalled again. I cannot make a connection to the hub for some reason. I am running php 8, maybe that is the issue (?).
not sure, no issues in 3.9 with php 7.4 and this version of the plugin.
But it's not the same issue as Adam reported, since that was H5P core related. So I think this best reported to H5P directly since it seems to be unrelated to Moodle itself.
- gemma
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
After racking my brains for 2 days trying to find the reason for this bug, finally discovered that a fix was suggested here https://github.com/h5p/moodle-mod_hvp/pull/472 almost 4 months ago !
Let's hope the H5P team will release a new version of the plugin so that it can finally become usable in Moodle 4.1.
In the meantime, if you have an easy access to your Moodle files, you can apply the fix yourself, it's only a few lines to be changed. I've done it on my Moodle test sites, and can report it's working well. 😉
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
I've spent pretty much half the day trying to figure out how to get the h5P "Adding a new Interactive Content" to work. The Select Content Editor shows up, no matter which content type I choose nothing happens, when I press install.
I see above there is a fix, but I could not find in my files where to make the proper changes. I did open the classes/framework.php file but do not see the 4 items listed on the fix which reference changing "stream" to "filename"?
Maybe I'm misunderstanding something , any help would be greatly appreciated,
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
The file that needs fixing is located at YOURMOODLESITE\mod\hvp\classes\framework.php
and you can view the patch at https://github.com/marsh0lion/moodle-mod_hvp/commit/c64aaae370212bc0bda2a6fdc6d5c1187ce318a5
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
It shows the plugin only but cannot find individual content-type files to upload directly.
Re: Can't 'get' activities in H5P Interactive Content Plugin [Moodle 4.0]
I made the changes in framework.php and it really works well and solves my problem.
I noticed that people are facing this problem since January 2023, but still it is not updated in the plugin.
Hope soon we will receive the new update.
Thanks once again for the solution.