Bitcoin Forum

Other => Meta => Topic started by: Little Mouse on March 01, 2023, 04:22:19 PM



Title: What image type forum supports?
Post by: Little Mouse on March 01, 2023, 04:22:19 PM
I was trying to upload a webp image on an image hosting site and implement it here but I failed. I tried with 2 different sites and still, the result was the same. The image wasn't displayed. So, I took a screenshot and used that image, and finally, that worked. What was wrong with my initial webp file? Is it a problem from image hosting site or from bitcointalk? Can someone explain a little about this?


Title: Re: What image type forum supports?
Post by: PX-Z on March 01, 2023, 04:27:27 PM
That's it. Just use .png or .jpg file image instead of webp. Considering this is an old version of smf so highly likely that it's the case.

Edit: i found this smf thread[1], even the latest versions doesnt support the same file type.

[1] https://www.simplemachines.org/community/index.php?topic=582141.0


Title: Re: What image type forum supports?
Post by: GazetaBitcoin on March 01, 2023, 08:07:19 PM
I was trying to upload a webp image on an image hosting site and implement it here but I failed. [...] Is it a problem from image hosting site or from bitcointalk?

Well, based on pure logic, since you could not upload your .webp image on the image hosting site, what's the connection with the forum? :) It's a problem that the respective image hosting site does not let you upload .webp images.

I tried with 2 different sites and still, the result was the same.

This should have explained you already that there is no connection between the forum and the sites where you tried to upload your image...

So, I took a screenshot and used that image, and finally, that worked.

Yes, that worked, because the screenshot was saved as .jpg or .png and the image hosting site was accepting this type.

What was wrong with my initial webp file?

There was nothing wrong. It's just the image hosting site did not accept this format. I tried to upload a .webp image on imgur and it doesn't work. This is what it shows:

https://i.ibb.co/BZ42nD8/1zAXyZs.png



As far as I know, according to theymos, only forum limitation regarding images is the one about their size:

1.5 does really suck, 2.5 would be perfect
OK, I increased it to 2.5.

If you have any other complains, well...


 :D


Title: Re: What image type forum supports?
Post by: Cantsay on March 01, 2023, 08:27:49 PM
[~snipped~]
There was nothing wrong. It's just the image hosting site did not accept this format. I tried to upload a .webp image on imgur and it doesn't work. This is what it shows:
[~snipped~]

It also happened to me, but I wasn't using imgur as my image hosting site I used imgbb.com. Although, it didn't display any error like that of imgur but still yet the forum could render the image, so I had to delete the whole post because I was quoting an Op for visibility.


Title: Re: What image type forum supports?
Post by: joker_josue on March 01, 2023, 08:39:27 PM
It also happened to me, but I wasn't using imgur as my image hosting site I used imgbb.com. Although, it didn't display any error like that of imgur but still yet the forum could render the image, so I had to delete the whole post because I was quoting an Op for visibility.

But the forum does not render images.
Honestly, I don't see much need in using .webp files, since a .png or .jpeg 90% has more than enough quality for most scenarios here on the forum.


Title: Re: What image type forum supports?
Post by: LoyceV on March 01, 2023, 09:01:25 PM
As far as I know, the forum's image proxy is limited to GIF, PNG and JPG (probably also JPEG).

Someone should setup an image host dedicated only to Bitcointalk, that converts all images to a working format.


Title: Re: What image type forum supports?
Post by: GazetaBitcoin on March 01, 2023, 09:12:45 PM
It also happened to me, but I wasn't using imgur as my image hosting site I used imgbb.com. Although, it didn't display any error like that of imgur but still yet the forum could render the image, so I had to delete the whole post because I was quoting an Op for visibility.

This could happen for various reasons... For example: was the picture larger than 2.5 MB? If yes, this is the reason.

Another reason: how did you try to upload the picture on the forum? Simply by adding its link between img-/img brackets? I mean this link: https://imgur.com/a/i5LE0HB.

If yes, again, this is the reason. You don't have to put between img-/img brackets the direct link to the pic. Instead, you have to have to click on the uploaded picture, in order to open it in a new tab, then right-click on the pic after you uploaded it on ImgBB and select "Copy link" or "Copy image location". By doing so, you'll get a link ending in ".png" or ".jpg". And that is the link you should insert between img-/img.

Example: if you'll type this inside your post, no image will be displayed:

Code:
[img]https://ibb.co/25JPKx9[/img]

Trying to write the above BBCode sequence inside your topic will end up in this:

https://i.ibb.co/SyB95Cc/Untitled5.png

That is a picture I uploaded on ImgBB. Now I open it in a new tab. For doing that I either click on it or copy that URL and paste it in a new tab. Once the image is displayed in a new tab I right-click on it and select "Copy image location". This generates a new URL, ending in ".png": https://i.ibb.co/7bhVyPf/Untitled4.png. And this is what you have to place between img-/img:

Code:
[img]https://i.ibb.co/7bhVyPf/Untitled4.png[/img]

Now the image is displayed:

https://i.ibb.co/7bhVyPf/Untitled4.png



Then, if none of these work, always remember:



Title: Re: What image type forum supports?
Post by: joker_josue on March 01, 2023, 09:23:10 PM
Someone should setup an image host dedicated only to Bitcointalk, that converts all images to a working format.

I've thought about setting up this type of service.
But I was afraid that there would be little adherence, since there are already so many equivalent services, that I didn't even try. :-\


Title: Re: What image type forum supports?
Post by: LoyceV on March 02, 2023, 09:49:48 AM
I've thought about setting up this type of service.
But I was afraid that there would be little adherence, since there are already so many equivalent services, that I didn't even try. :-\
I thought about it too, but I wouldn't know how to do it. And there's legal implications: you'll need to remove illegal images, or copyrighted images.
The way I envisioned such a service is making it completely transparent, so anyone can download a backup of all images. If your service ever disappears, a new one could be started and all that's needed is replacing the links in the forum's database to the new domain name. It would be a way to ensure images are still available in the far future. I started by using tinypic, but they quit years ago so all those images are gone.


Title: Re: What image type forum supports?
Post by: joker_josue on March 02, 2023, 10:12:54 AM
I thought about it too, but I wouldn't know how to do it. And there's legal implications: you'll need to remove illegal images, or copyrighted images.
The way I envisioned such a service is making it completely transparent, so anyone can download a backup of all images. If your service ever disappears, a new one could be started and all that's needed is replacing the links in the forum's database to the new domain name. It would be a way to ensure images are still available in the far future. I started by using tinypic, but they quit years ago so all those images are gone.

The problem with this is the storage of images. Such a backup would take up quite a few gigabytes. But I think the idea is very interesting, and I could think of something.

The service I thought of would use Amazon Cloud hosting or some similar service. To help manage the accommodation. Basically I would only be managing the front end of the site, where the hosting would be provided by these services. Do you think that would be interesting?


Title: Re: What image type forum supports?
Post by: BitcoinGirl.Club on March 02, 2023, 04:06:31 PM
Someone should setup an image host dedicated only to Bitcointalk, that converts all images to a working format.
You, TryNinja are two guys I see are capable to do that.

OP, there are image converter sites online, free tools. You can convert webp, svg or any other format to png, jpeg etc. Use them.


Title: Re: What image type forum supports?
Post by: aysg76 on March 02, 2023, 04:38:48 PM
You, TryNinja are two guys I see are capable to do that.
Yes they can figure it out and if @TryNinja can figure it out he would definitely come up with this service as he is usually working on lot of tools to help forum members.

OP, there are image converter sites online, free tools. You can convert webp, svg or any other format to png, jpeg etc. Use them.
Only if we are trying to upload image in any format that's not supported by the image hosting sites as usually we have them in .jpg or .png format as I have no problem in image uploading ever but yes there are many services through which you can easily convert the format without even compressing the file.


Title: Re: What image type forum supports?
Post by: Little Mouse on March 03, 2023, 08:35:53 AM

This should have explained you already that there is no connection between the forum and the sites where you tried to upload your image...
I think I had bad choices of word. I was able to upload the file on image hosting site without any issue, it allowed me to upload webp file if I'm not mistaken but when I implemented the bbcode on bitcointalk, the image wasn't displayed here.

As far as I know, the forum's image proxy is limited to GIF, PNG and JPG (probably also JPEG).
I see. I have used gif, png and jpg. Can't remember if I have ever used JPEG or not.


Title: Re: What image type forum supports?
Post by: GazetaBitcoin on March 03, 2023, 08:09:42 PM
This should have explained you already that there is no connection between the forum and the sites where you tried to upload your image...
I think I had bad choices of word. I was able to upload the file on image hosting site without any issue, it allowed me to upload webp file if I'm not mistaken but when I implemented the bbcode on bitcointalk, the image wasn't displayed here.


Ohhhh, now I understand what you meant! Yes, this changes things completely... But are you sure you actually managed to upload the .webp picture on that site? Do you remember, at least, what site it was? I am asking because not many websites accepts .webp images and, perhaps, you do not remember well... As you saw, in my earlier post, imgur also does not allow uploading .webp images, notImgBB. I mean maybe we could try this again, following exact steps you made first, in order to see exactly where the problem is.



I see. I have used gif, png and jpg. Can't remember if I have ever used JPEG or not.

I used .jpeg (https://bitcointalk.org/index.php?topic=5439659.msg61849342#msg61849342) today and it works fine. .gif and .png also work for sure (unless dimension limit of 2.5 MB is reached).


Title: Re: What image type forum supports?
Post by: SquirrelJulietGarden on March 04, 2023, 03:47:12 AM
Forum is powered by SMF software and it's good to read documents for SMF software for general information. However, theymos customize some forum features and it's no better place to check it than in the forum.

Forum user avatar gives you most up to date information.
Quote
Select the avatar you want to upload. It must be no more than 120px wide, 80px tall, and 100 KiB in size. It must be a non-animated PNG, GIF, or JPEG image. It must be safe for work. To remove your avatar, submit this form without choosing any file to upload.

It does not provide all information about accepted images here but about image type, it has enough information.

Animated avatars were disabled since February 2019.
OK, APNGs are now detected. Old ones are grandfathered for now, in part because people have ongoing campaigns, but in the future I might (or might not) go through and remove them.


Title: Re: What image type forum supports?
Post by: UserU on March 04, 2023, 06:19:08 AM
As far as I know, the forum's image proxy is limited to GIF, PNG and JPG (probably also JPEG).

Someone should setup an image host dedicated only to Bitcointalk, that converts all images to a working format.

Actually JPEG is JPG. JPG because Windows back then only supported the three-letter file extension instead of four, then it stuck. :)

Quote
JPGs and JPEGs are the same file format. JPG and JPEG both stand for Joint Photographic Experts Group and are both raster image file types. The only reason JPG is three characters long as opposed to four is that early versions of Windows required a three-letter extension for file names.

Source: https://www.adobe.com/creativecloud/file-types/image/comparison/jpeg-vs-jpeg-2000.html#:~:text=JPGs%20and%20JPEGs%20are%20the,letter%20extension%20for%20file%20names.


Title: Re: What image type forum supports?
Post by: joker_josue on March 04, 2023, 07:59:17 AM
Actually JPEG is JPG. JPG because Windows back then only supported the three-letter file extension instead of four, then it stuck. :)

That's true, but when you set up a site that accepts images, you have to indicate the accepted extensions.

If the .jpeg version is not included, the system will not accept it, despite being the same type of file as the .jpg. Usually who does this kind of configuration, he knows this and tries to cover these details in the image extensions.


Title: Re: What image type forum supports?
Post by: UserU on March 04, 2023, 08:14:54 AM

That's true, but when you set up a site that accepts images, you have to indicate the accepted extensions.

If the .jpeg version is not included, the system will not accept it, despite being the same type of file as the .jpg. Usually who does this kind of configuration, he knows this and tries to cover these details in the image extensions.

Gotcha, so it boils down on whether to include the lesser-used jpeg or just go mainstream (i.e. ignore it). Interestingly some hosting sites would auto-convert it to WEBP such as Imgbb.

Seems that this forum does support it with the sample below.

https://www.linkpicture.com/q/sample_640t426.jpeg


Title: Re: What image type forum supports?
Post by: LoyceV on March 04, 2023, 08:51:15 AM
That's true, but when you set up a site that accepts images, you have to indicate the accepted extensions.
A proper image converter doesn't care about the extension, but checks the actual file format.
If you create a site for hosting images, you can automatically convert the images to the desired extension.

This got me thinking: what if I just change the extension to jpg without changing the file itself?
Test:
https://loyce.club/other/a04erVL_460swp.webp.jpg
(source: the first webp-image I found on 9gag.com (https://9gag.com/gag/a04erVL))

How's this for a workaround? :D I think theymos' image proxy is dumb enough to only check the extension (and file size), while the browser is smart enough to figure out the actual file format and display the image correctly :D


Title: Re: What image type forum supports?
Post by: joker_josue on March 04, 2023, 09:06:35 AM
How's this for a workaround? :D I think theymos' image proxy is dumb enough to only check the extension (and file size), while the browser is smart enough to figure out the actual file format and display the image correctly :D

By the way, you can do this with almost any image. Except for more complex extensions - for image programs. Even on your PC changing the extension, it recognizes the image as another type of file. If you test change to .bmp, a very little used format, it opens the file the same on your PC. It's pretty curious how the imaging system works. :)


Title: Re: What image type forum supports?
Post by: LoyceV on March 04, 2023, 10:04:29 AM
By the way, you can do this with almost any image. Except for more complex extensions - for image programs. Even on your PC changing the extension, it recognizes the image as another type of file. If you test change to .bmp, a very little used format, it opens the file the same on your PC. It's pretty curious how the imaging system works. :)
I often use file (standard program) or identify (part of ImageMagick) to see file details. The latter can also be used from PHP, so that's where I would start as a backend for an image host.