I know that storing images as a “File sharing” thing isn’t allowed, but does it apply to all forms of images, uploaded to server and uploaded to DB with Base64 encoding?
I’m working on adding Image Support for my project, and I don’t want to have any troubles.
It depends on what you plan to use the upload feature for. If it’s for a purpose not directly related to file sharing (like profile photos) it should be OK.
But there’re also no need to store them in the database as base64. Databases have a much smaller storage limit, and doing also consumes way more resource than just loading a file, which means that you are more likely to hit a database limit if you store images in this way.
I’m not Admin, but this sounds like a form of file sharing to me. Even if the images are encoded as base64 to be distributed, they’re still being shared.
It’s just a few hundred MB I think, something like around 300-800 MB but don’t quote me on this. But whatever the limit is it’s much smaller than the disk limit.
A long time ago a person comes up with am exact same idea like this. I cannot remember what is that topic but Admin did some calculations and it’s totally not worth it.
My interpretation of the rules is that images you host should be viewable by many people, and the sharing of such files is not the main purpose of your site. In my opinion, a private image sharing service (essentially what you are proposing), is not allowed. I would recommend you use Amazon S3 for this.
edit: also, don’t use base64 if your putting images in a database, store the image binary instead (it’s much smaller)
Image sharing sites are not allowed. That’s the rule. The rule doesn’t say anything about specific methods of how that image sharing site works.
While there is no fixed limit on database space used as far as I am aware, fair usage limits apply, and if we find out that the database server is being filled by you thinking you found a free way to get unlimited storage, we’re going to take actions that you may not like.
And storing files in a database is an objectively very inefficient way to handle uploaded files. Serving a file directly from storage is very inefficient, but firing up a PHP script that opens a network connection to retrieve a file from a database server is much slower, and may cause you to run into other account limits.
And storing them as base64 encoded text is also a very inefficient way to do it. MySQL can just store binary data as BINARY, VARBINARY or BLOB data types (analogous to CHAR, VARCHAR and TEXT for textual data). By adding base64 encoding you’re just wasting disk space and CPU cycles.