1

How can I make it so that a user can upload and then store their word document in a database so that they can download it as a word document later?

jister13
  • 83
  • 1
  • 9

2 Answers2

1

Storing files in a regular RDBM is generally considered to be bad practice. I would recommend storing the files on the file system and storing the path to the file in some kind of VARCHAR or TEXT field in the database. If you're desperate to store the file in the database look at storing it in a BINARY blob or base64 encoding it.

James C
  • 14,047
  • 1
  • 34
  • 43
0

The Word document should not be stored IN the database. A good practice would be to only store a link to a file within the public scope of your website.

mimipc
  • 1,354
  • 2
  • 14
  • 28