Open jessienab opened 1 year ago
I agree it would be a good idea to locally generate the QR codes, if only to avoid the QR codes breaking in the future if Google suddenly starts enforcing SSL on those images (or breaks them in some other way). I think that endpoint is already deprecated.
The implementation might be tricky, though. I assume Data URIs would work for the 3DS and Wii U, but I generally want ImageShare to work on other old browsers, and embedding URI images wasn't widely supported until 2010-ish: https://caniuse.com/datauri
That library looks like it generates a PNG file and then just embeds it normally, which should work fine, but there might need to be some additional code in ImageShare for cleaning up those files afterwards. I'll have to look into that!
ImageShare now uses the goQR.me API for rendering QR codes, since the Google API appears to be shut down (it has been marked as deprecated for a while) and goQR supports both HTTP and HTTPS connections. Ideally ImageShare still needs to move to a local solution for QR code generation.
To reduce issues relating to user privacy, it would be ideal to add support or implement the use of a self-hosted/local piece of code, to generate QR codes of image URLs.
PHPQRCode seems to be a viable PHP based project for this kind of work, however I imagine it stores the image locally. I guess a solution to that would be exporting the generated image as a set of base64 text the browser would present? Can the 3DS Browser even accept that kind of data?
There are some other QR generating alternatives, but I haven't found one (in a quick search) that doesn't require payment or an account on someone's end.
Thank you for the code and service!