Piwigo / piwigo-videojs

Videojs port for piwigo. Play your videos on your web gallery!
http://piwigo.org/ext/extension_view.php?eid=610
GNU General Public License v3.0
67 stars 46 forks source link

Not Compatible with Piwigo 12.0 #181

Closed jesuschristpose closed 2 months ago

jesuschristpose commented 3 years ago

Hi,

Not sure if this involved much work or just changing it as marked as compatible, but Piwigo 12 doesn't like current master version. Would love to have this back

Thanks

tomchiverton commented 2 years ago

Work seems done, but https://piwigo.org/ext/extension_view.php?eid=610 says it isn't so maybe just the store page needs update ? Have you tried just putting the GitLab code on a Piwigo 12 / PHP8 ?

plegall commented 2 years ago

@erAck @xbgmsharp in the case of this plugin, the solution is a bit more complicated than bcef4a0df77f96182b82b2f174a73216a8b54eb9 (adding Has Settings). This new setting will automatically generate the link to the admin page of the plugin as admin.php?page=plugin-<plugin_id>. In the case of piwigo-videojs, the link will be admin.php?page=plugin-piwigo-videojs and it doesn't work because Piwigo thinks it's plugin "piwigo" and tab "videojs" which is not the case. All plugin with a "-" in its identifier will have the same problem.

Second issue: Piwigo expects the admin page to be plugin_directory/admin.php not plugin_directory/admin/whatever.php.

For now, I think it's better to simply remove the Has Settings line :-/

erAck commented 2 years ago

The links are actually admin.php?page=plugin&section=piwigo-videojs%2Fadmin%2Fadmin.php&tab=config admin.php?page=plugin&section=piwigo-videojs%2Fadmin%2Fadmin.php&tab=sync and look wrong but they do work for me.

plegall commented 2 years ago

they do work but not right after you activate the plugin. It works because the plugin overload the link with the function vjs_admin_menu. This overloading is not possible "right after" activation.

mike-e-allen commented 2 years ago

i still get this error:

Resolution : Warning: Undefined array key "resolution" in /home/madisonallen/madworlddsign.com/dev.portraits/_data/templates_c/p6jhns^bc1fa7ff832e17164e7eb8667013c3576703f98d_0.file.admin_config.tpl.php on line 268
/> Yes  Warning: Undefined array key "resolution" in /home/madisonallen/madworlddsign.com/dev.portraits/_data/templates_c/p6jhns^bc1fa7ff832e17164e7eb8667013c3576703f98d_0.file.admin_config.tpl.php on line 270
checked="checked"/> No
Resolution switcher.

i was able to fix it by inserting this line after line 95 in admin_config.tpl: 'resolution' => get_boolean($_POST['vjs_resolution']),

and then changing line 175 in admin_config.tpl from <input class="submit" type="submit" value="{'Save Settings'|@translate}" name="submit"/>

to <input class="submit" type="submit" value="{'Save Settings'|@translate}" name="save_config"/>

not sure if this is all that was needed or if this is the "correct" fixes.

tomchiverton commented 2 years ago

I think it's compatible now. Seems to work OK here... marked compatible OK on https://piwigo.org/ext/extension_view.php?eid=610

https://rachaelandtom.info/photos/picture/12253-mov_0095/category/356-rachael_vs_big_boss

tomchiverton commented 2 years ago

This can be closed