
Originally Posted by
mutago
Is it ok to save the images,files and videos to database, won't it cause recovery headache
actually, it can make recovery easier, because all your data is in the same place and is easier to backup (or, in cases where the DB is on a different server than your scripts, then it doesn't need to recovered at all).
The "trick" is to not have to query the DB every time you want to, e.g., serve a video. I haven't got this "down" yet, but the general idea is like so:
1. "THE content" is what's in the DB.
2. Set up a folder on your website to "cache" copies of the content in a place that is accessible to the web.
3. Your webpages ask for the content from your "cache" folder.
a. if a copy of the content is in the cache folder, just use it; don't bother the DB.
b. if the content isn't there, ask the DB for a copy (e.g., by using mod_rewrite to call a script).
... The script gets the content from the DB, and also creates a copy in the cache folder so it'll be there next time.

Originally Posted by
mutago
considering the site to be built, what are suggestions.
As @keyboard pointed out, it's a very big task. You have a big learning experience in front of you—which is cool, but if you just "need it done," you might need to look for an alternate solution (find similar, existing software; or hire someone).
Bookmarks