@Ryan, our team know how to handle the logic before the template
engine, the complication is that we are building an online CMS, and
the user will have access to the HTML only, that's why we can't have
hard coded or predefined sizes in the core, the user can create his
own template.
@Edmund, yep, we have the same problem :) I don't know how you planned
to use your resizing proxy, as long as I know, you will need to send
the dimensions with the URL, something like:
http://images.mysite.com/ondfou32hfujfj/200/400 but that isn't an
alternative for us.
One solution we found was force the user to create an "image schema"
on the admin interface, this way:
1) The user register a new schmea by submitting a form with the
values: 200 x 300, centered crop
2) The system save this new schema on the database and return an
unique ID for it, let's say: 2k9u8l
3) Now the user will have an relation with the schemas and it's IDs
4) The user implement the ID on the view: <img src="{{ image(file,
'2k9u8l') }}" />
5) The output would be something like <img
src="/image/2k9u8l/theuserimage.png" />
6) This way the system know what is the image and what to do with it
by consulting the database for this image schema.
Pros: This way we wouldn't have resizing parameters on the url,
ensuring maximum system protection agains resizing flood.
Cons: A whole new admin panel to build and it will be a lot more
dificult for users to implement and understand...
--
Att,
Alan Hoffmeister
2012/5/22 Edmund von der Burg <
ev...@ecclestoad.co.uk>: