Configuration
As is standard, some configuration recommendations to get started with a more feature-full setup.
Video support
Enabled by adding the piwigo-videojs
plugin, and then following the wiki. The files to edit are in the Docker image, which can be accessed via docker exec -it piwigo bash
.
Instructions
Enable uploading of videos and more permissive filenames, by editing /gallery/local/config/config.inc.php
and changing a couple of configuration variables (edit using nano
):
... $conf['upload_form_all_types'] = true; ... $conf['sync_chars_regex'] = '/^[a-zA-Z0-9-_., \[\]()]+$/'; ... $conf['show_exif_fields'] = array( 'Make', // photo-related metadata 'Model', 'ExifVersion', 'Software', 'DateTimeOriginal', 'FNumber', 'ExposureBiasValue', 'FILE;FileSize', 'ExposureTime', 'Flash', 'ISOSpeedRatings', 'FocalLength', 'FocalLengthIn35mmFilm', 'WhiteBalance', 'ExposureMode', 'MeteringMode', 'ExposureProgram', 'LightSource', 'Contrast', 'Saturation', 'Sharpness', 'bitrate', // video-related metadata 'channel', 'date_creation', 'display_aspect_ratio', 'duration', 'filesize', 'format', 'formatprofile', 'codecid', 'frame_rate', 'latitude', 'longitude', 'make', 'model', 'playtime_seconds', 'sampling_rate', 'type', 'resolution', 'rotation', ); ...
This works well for the following file formats: mp4, ogg, webm. If using the LinuxServer Docker image, the required tools will have been included already.
Issues
pwg_representative
needs to be created in the same folder layer as the video, i.e. the media folder is no longer read-only and requires write permissions to generate video screenclips. Video playback itself still works, but there is no preview. See issues #97 and #152, with one user suggesting to manually add symbolic links instead as a workaround. Consider this answer for a more permanent solution...?- Not ready for Piwigo 11:
- Somehow after the first synchronization run, the form clears out and subsequently throws a
null
reference error in many PHP scripts. Commenting out the problematic part alleviates the symptoms, specifically the block mentioned below.
/*
// Merge default value with user configuration
if (isset($conf['vjs_sync']))
{
$sync_options = array_merge(unserialize($conf['vjs_sync']), $sync_options);
}
if(isset($_POST['mediainfo']) && isset($_POST['ffmpeg'])) {
// Override default value from the form
$sync_options_form = array(
'mediainfo' => $_POST['mediainfo'],
'ffmpeg' => $_POST['ffmpeg'],
...
'subcats_included' => isset($_POST['subcats_included']),
);
// Merge default value with user configuration
$sync_options = array_merge(unserialize($conf['vjs_sync']), $sync_options_form);
// Update config to DB
conf_update_param('vjs_sync', serialize($sync_options));
}
*/
Infinite scroll
Link: https://piwigo.org/ext/extension_view.php?eid=493 ( source)
This one is a no-brainer addition, otherwise you shall be consigned to manual page-switching.
Note however this scroll does not extend to albums, i.e. albums will still be paginated with at most 12 per page. Organize your content wisely.