Friday, January 30, 2009

Image Association with Records

I'm looking for some advice for images.

I've got a system for an advertising piece on a app I'm working on.
There is a 'companies' table that has all the company info and we need
to add a "logo" field and the ability to upload up to 5 images. What's
the best way to do this?

I don't want to save all the images in a database. I want to hold them
in a file system (that's how it's currently set up). My thought to to
simple save them in /img/companies/1_logo.jpg and then /img/companies/
1_[1 2 3 ...].jpg. Write an image model to associate images with
records, and custom write the adding, updating and deleting of images.
(This is how the current system works, but I want to port the system
over to cakePHP).

Any better suggestions?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: