> I'm a cake beginner and also pretty much a php beginner, as until now > i only had to understand what it (can) do, but never had to code > myself. > > In order to develop my skills i started to code a little portfolio-app > and right now I'm running into some rather conceptual questions: > > I want to upload pictures and save and keep the original, and then > resize them in two versions for display (big and thumb). The upload is > working, now i wonder where the resizing would take place in a MVC > approach - in the model or in the controller? My initial Idea is to do > it in the controller->view action to be able to recreate them if I > need to change sizes for layout reasons. But somehow it seems to me > that the model would be more appropriate. > > Second question - Image serving: I could save the processed Images in > the webroot/img folder and in my views access them through a direct > link or I could read them and output them as raw data through a > template, providing the correct header information etc. What are the > pros and cons of either solution?
check out http://www.ad7six.com/MiBlog/GenericFileUploadBehavior - should fit the bill perfectly for you. hth, jon -- jon bennett w: http://www.jben.net/ iChat (AIM): jbendotnet Skype: jon-bennett --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---
