Google's formats: webp, webm...

56 views
Skip to first unread message

tlahuizcalpantecutli

unread,
May 12, 2022, 11:08:11 AM5/12/22
to Gallery 3 Users
Team, how can I allow webp/webm files to be uploaded through 'add file' into my gallery, to make them available to users, please?  For the most part, their browsers support them.

I assume I have to add it to the list of known mime's in '/system/config/mimes.php'?

What else?

I'd rather ask before changing anything...

Thanks!

t

(just in case you want to know, I am using version 3.1.5 under linux fedora 36, using php8.1 and apache ... so far, so good)

Kazuo Kuroi

unread,
May 12, 2022, 11:53:45 AM5/12/22
to Gallery 3 Users
G3 was made well before the standardization of  such a thing.

Mime will need to be updated but there may be some webp/webm APIs or libs that need to be leveraged.

Braaaad!

J.R.

unread,
May 13, 2022, 4:42:18 PM5/13/22
to gallery...@googlegroups.com
Exactly. If I wanted to do this kind of thing and I had a large Gallery 3 installation I also wanted to keep, I would find a modern app designed to handle the new stuff and use that, placing image-links onto my Gallery 3  pages to the appropriate pages on that new app. Trying to retrofit most of the new stuff onto a Gallery 3 platform that was created almost 20 years ago, before this stuff even existed is impractical.

Our goal here to keep Gallery 3 running in the new server environments. To rewrite it from scratch to accommodate all that has changed and been added to the world makes no sense, as there are already a lot of far newer apps out there that already do that stuff, most of them low or no-cost.

-- J.R.
--
WHEN USING AN EMAIL PROGRAM to reply to this message, click REPLY TO LIST or REPLY TO ALL so your reply goes out to everyone in the group. If you click REPLY or REPLY TO SENDER Google will *only* send your reply to the original author (not recommended).
 
To post a NEW MESSAGE to the group, send an new email to:
gallery...@googlegroups.com
 
To view or sign in to this group on the web, use this URL:
https://groups.google.com/forum/#!forum/gallery-3-users
---
You received this message because you are subscribed to the Google Groups "Gallery 3 Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gallery-3-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gallery-3-users/b2c6b5da-9c54-4c02-ba80-24e873968bdb%40irixnet.org.

Brad Dutton

unread,
May 13, 2022, 5:30:10 PM5/13/22
to Gallery 3 Users
Generally speaking, adding additional file types shouldn't be difficult. With the following 2 changes:
I was able to upload webp and webm files to my test gallery:
https://gallery7.dev.duttonbrosllc.com
(the last 2 items in the list)

Brad Dutton

unread,
May 13, 2022, 5:37:28 PM5/13/22
to Gallery 3 Users
This was with GraphicsMagick and ImageMagick, the GD library didn't convert the file for thumbnail generation.

Gerardo L. Cahn

unread,
May 13, 2022, 10:04:53 PM5/13/22
to gallery...@googlegroups.com

Thanks a lot, Brad, as well as J.R. and Kazuo ... I'll go grab this from github over the weekend and play with it: great news!

Incidentally, I know what J.R. is talking about: I tread carefully around gallery3 to avoid --or at least to delay-- having to migrate to the alternatives J.R. mentions.  I dread it both for sentimental reasons as well as for effort involved, which is why I so appreciate the time and know-how you guys selflessly offer.

I was just hoping that this would not be a major change, crossed my fingers and jumped.

Thanks again,

t

To view this discussion on the web visit https://groups.google.com/d/msgid/gallery-3-users/9483282e-6dc4-4937-8a1b-bf6275839548n%40googlegroups.com.
-- 
// Gerardo L. Cahn <ger...@niuk.org>
//  linux, mac ... and, well, yes,
//        ((windows too)).

Kazuo Kuroi

unread,
May 13, 2022, 11:09:04 PM5/13/22
to Gallery 3 Users
In the future if I move off G3 I intend to continue posting here, testing it etc. I think it's important to forge good relationships.

Glad this was fixed.

Gerardo L. Cahn

unread,
May 20, 2022, 12:38:45 PM5/20/22
to gallery...@googlegroups.com

Team, uploading webP images works beautifully (thanks again for that!).

However, I can't upload webM videos: it fails with a 'red cross' (see pic); the log shows the error listed below...  do I need to install additional modules for this? (mp4 videos I can upload and play with no issues).

The file I tried to upload for the pic below is the same sample file that Brad put in his gallery, incidentally.

Thanks for any guidance, as always...

Best,

t

from ../gallery/logs/..:

2022-05-20 11:48:02 -04:00 --- error: TypeError [ 0 ]: mysqli::real_escape_string(): Argument #1 ($string) must be of type string, array given
/usr/share/gallery3-3.1.5/system/libraries/Database_Mysqli.php [ 87 ]
#0 /usr/share/gallery3-3.1.5/system/libraries/Database_Mysqli.php(87): mysqli->real_escape_string()
#1 /usr/share/gallery3-3.1.5/system/libraries/Database.php(429): Database_Mysqli_Core->escape()
#2 [internal function]: Database_Core->quote()
#3 /usr/share/gallery3-3.1.5/system/libraries/Database_Builder.php(822): array_map()
#4 /usr/share/gallery3-3.1.5/system/libraries/Database_Builder.php(1007): Database_Builder_Core->compile_values()
#5 /usr/share/gallery3-3.1.5/modules/kohana23_compat/libraries/MY_Database_Builder.php(48): Database_Builder_Core->compile()
#6 /usr/share/gallery3-3.1.5/system/libraries/Database_Builder.php(957): Database_Builder->compile()
#7 /usr/share/gallery3-3.1.5/system/libraries/ORM.php(823): Database_Builder_Core->execute()
#8 /usr/share/gallery3-3.1.5/modules/gallery/libraries/MY_ORM.php(34): ORM_Core->save()
#9 /usr/share/gallery3-3.1.5/modules/gallery/libraries/ORM_MPTT.php(76): ORM->save()
#10 /usr/share/gallery3-3.1.5/modules/gallery/models/item.php(396): ORM_MPTT_Core->save()
#11 /usr/share/gallery3-3.1.5/modules/gallery/controllers/uploader.php(197): Item_Model_Core->save()
#12 /usr/share/gallery3-3.1.5/modules/gallery/controllers/uploader.php(62): Uploader_Controller->_add_item()
#13 [internal function]: Uploader_Controller->add_photo()
#14 /usr/share/gallery3-3.1.5/system/core/Kohana.php(302): ReflectionMethod->invokeArgs()
#15 /usr/share/gallery3-3.1.5/system/core/Event.php(208): Kohana_Core::instance()
#16 /usr/share/gallery3-3.1.5/application/Bootstrap.php(67): Event_Core::run()
#17 /usr/share/gallery3-3.1.5/index.php(124): require('/usr/share/gall...')
#18 {main}

Brad Dutton

unread,
May 20, 2022, 12:49:31 PM5/20/22
to Gallery 3 Users
Are you by chance running PHP 8.1?

Gerardo L. Cahn

unread,
May 20, 2022, 1:00:22 PM5/20/22
to gallery...@googlegroups.com

Gerardo L. Cahn

unread,
May 20, 2022, 1:00:41 PM5/20/22
to gallery...@googlegroups.com

...((yess...))...

On 5/20/22 12:49, Brad Dutton wrote:

Brad Dutton

unread,
May 20, 2022, 1:07:30 PM5/20/22
to Gallery 3 Users
8.1 doesn't fully work yet, I'm having to make changes to get gallery working on this version. Try to stick with 8.0 for a little while longer if you can.

tlahuizcalpantecutli

unread,
May 20, 2022, 1:18:50 PM5/20/22
to Gallery 3 Users
Thanks, Brad ... nah, I'll wait for you.  No rush at all.  We'll convert webm's to mp4's if they pop up.

Best,

t

Reply all
Reply to author
Forward
0 new messages