Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

How to automatically limite the size of the images into the website builder on odoo v8 ?

By
Pedro Cachaca
on 9/11/14, 7:11 PM 1,036 views

On Odoo online Version 7.saas~3, into the website builder, when replacing an image, the url is automatically generated with max_height=768 and max_width=1024,  example : /website/image?max_height=768&field=datas&model=ir.attachment&id=19&max_width=1024

This is good to limit the size of the image to be downloaded (I prefer not asking my customer to reduce the image size by himself and it is in some situation better to keep full size).

On odoo V8 RC01, installed on my own server, I don't have the same behavior. The URL is generated without max_height and max_width, and I don't find how to code this. Is it through templates ? theme files ?

Note: I can manually edit the html, but it is not good for me because if my customer replace the image later, the new image url will be generated without max_height and max_width.

Second Question : I have a page with many thumbnails. For these images, it could be fine if all the images are limited with max_height=150 and max_width=150. So I need to handle this.

Thanks!

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 9/11/14, 7:11 PM
Seen: 1036 times
Last updated: 3/16/15, 8:10 AM