Jump to content

Report system with screenshot support


joaosilva099

Recommended Posts

Yes, you can store images in the database, but it's not advisable and bad practice.

Do not store images in the database. Store images in directories and store references to the images in the database. Like store the path to the image in the database or the image name in the database.

Images can get quite large 1MB >. Even if it's a small image, it's still bad practice. You're putting extra hits on your database transactions that you can completely avoid. No big websites stores images in their database. Craigslist doesn't do it. Facebook doesn't do it. It's not a good idea.

Do as the guy said, store just the references.. what Ciber said is wrong.. you could do something like INSERT INTO yourtablename VALUES ('reportedaccount', 'reportreason', 'pathtoscreenshot')

Link to comment

Actually it's not wrong. Depends on how much network you count on, besides there are many sites that do use this method, tho it's not quite practical, it's a good method and saves Web host space.

You could link the file path asigning it to the report, there are more than one way of achieving the same thing. I think it's not safe to say that one way or another is right or wrong.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...