terrid25
terrid25

Reputation: 1946

Symfony - uploading images and saving as blob

I'm using SF1.4 and Propel and I'm having a slight problem with trying to save images to a field in my database.

Does anyone have a small example that I could work from?

Upvotes: 1

Views: 1586

Answers (2)

Luis Berrocal
Luis Berrocal

Reputation: 336

I've had a bad experience saving images as blobs. Specially when you have to change your database engine. But if you still want to go that way. I found this useful http://oldforum.symfony-project.org/index.php/t/25699/ though its based on Doctrine.

Upvotes: 1

RusAlex
RusAlex

Reputation: 8575

Keep your images in a filesystem. Is there a special reason to store images in a db ? You can store only generated filename. Because storing blobs in mysql will freeze your application. Give this task to a webserver.

Upvotes: 5

Related Questions