Django Sorl Thumbnail Resizing error -


i"m been using django sorl thumbnail , encountered problem.

i set settings on template scale image larger 500 width , height resize around 500 width , height. problem , happen if image lower fixed settings height , width 500.the image scaled 500 width , height . how can fix problem image lower 500 width , height not need resize.

{ % thumbnail item.image "x500" im %}    <img src="{{ im.url }}">  {% endthumbnail %} 

enter image description here

i got solved it, have set upscale=false.

upscale boolean , controls if image can upscaled or not, default value true.

{% thumbnail item.image "x500" upscale=false im %}    <img src="{{ im.url }}"> {% endthumbnail %} 

then images lower 500px not upscaled.


Comments

Popular posts from this blog

linux - xterm copying to CLIPBOARD using copy-selection causes automatic updating of CLIPBOARD upon mouse selection -

qt - Errors in generated MOC files for QT5 from cmake -