Hi,
I’m adding video conversion to a site and hoping to structure it where a user can upload a single video to the panel and then have a conversion script running outside of kirby create multiple web-optimized versions. Ideally these versions would be transparent to the user, and the main original video would be the only one visible from the panel.
So right now I’m creating a subfolder within panel item’s content directory with the name of the video e.g.:
project/
example.mp4
example.mp4.txt
example/
example.webm
example.ogv
example.jpg
I could then using something like this plugin: Image URLs - How to remove string? to intercept video requests and prevent things being moved to the media directory… the only issue with this method is that these subfolders are being treated as subpages in the pages index?
I’ve also thought of doing this generation work directly in the media directory (which seems maybe more appropriate) but once the main video is accessed the hashed folder that I created via the
$file->mediaRoot()
(before accessing the video) gets wiped.
Would appreciate any advice on how to best handle this case!