WordPress project modern structure and H5P problems
Hi, for one of our projects we are using a project structure like https://roots.io/bedrock/ and it seems that H5p has some issues with it. So The H5p plugin doesn't respect that project structure and is not loading any resource it uses.
Basically I quess there may ways to fix but we using quick and dirty
in file class-h5p-plugin.php line 1105 (latest plugin version)
$rel_path = preg_replace('/^[^:]+:\/\/[^\/]+\//', '', $lib_url);
and in file class-h5p-content-admin.php
line 945
$url = preg_replace('/^[^:]+:\/\/[^\/]+\//', '', $upload_dir) . '/';
but it would be nice to get a H5P wordpress plugin version for these modern project structures
├── composer.json
├── config
│ ├── application.php
│ └── environments
│ ├── development.php
│ ├── staging.php
│ └── production.php
├── vendor
└── web
├── app
│ ├── mu-plugins
│ ├── plugins
│ ├── themes
│ └── uploads
├── wp-config.php
├── index.php
└── wp
icc
Tue, 09/05/2017 - 14:07
Permalink
Hi,Have you tried the latest
Hi,
Have you tried the latest 1.9.2 plugin?
Also, could you share which part of the URL is wrong? Is it the 'app' folder missing?
zeelandfamily
Thu, 10/05/2017 - 11:43
Permalink
Hi,yes we tried the latest
Hi,
yes we tried the latest
and in console all paths to js resources look like
https://wp-content/plugins/h5p/h5p-php-library/js/jquery.js?ver=1.9.4
icc
Thu, 10/05/2017 - 13:01
Permalink
I've created an issue for
I've created an issue for getting this fixed: HFP-1593
zeelandfamily
Mon, 12/11/2017 - 14:25
Permalink
Hi,we think we found the
Hi,
we think we found the problem
if we comment out the following in our config file everything works fine with the latest plugin version
define('WP_CONTENT_URL', CONTENT_DIR);
icc
Mon, 12/18/2017 - 10:52
Permalink
Great, thanks for sharing!
Great, thanks for sharing!
sindrefjell
Wed, 06/28/2023 - 16:14
Permalink
Update here
We are also running our site on bedrock and our not able to view h5p exercises on frontend or backend. Has there been any solve to this? We experience the following error code in the console.
Is there any fix to this issue?