Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Why do you have to specify the padding-bottom? Is it the image ratio (as 16:9 = 56.25%)? In that case, it would practically render the plugin useless for sites with many images with unknown size.


You can read about the padding-bottom technique at http://alistapart.com/article/creating-intrinsic-ratios-for-... It helps you preserve space for the image and prevents reflowing. If you have many images with unknown sizes there will be massive reflowing and the library can be tweaked to support that too if you really want it.


This would be awesome.

At the same time, one could use something like ImageMagick to find out the dimensions of the picture and set this ratio programatically (http://stackoverflow.com/questions/16266933/rmagick-how-do-i...)


Yes, server languages can do this job easily.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: