![]() |
Javascript Question - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: Javascript Question (/showthread.php?tid=65539) |
Javascript Question - wolfgang1983 - 06-24-2016 I thought I would post this question on here but not much to do with CI I have a img which I am using holder.js Code: <div class="header-wrapper "> I need to get the height of the img on my javascript but all ways return 0 Code: <script> Any ideas and examples? RE: Javascript Question - ivantcholakov - 06-24-2016 I think, before measuring the height the image has to be loaded first for sure. This does not happen on document.ready event. See https://github.com/desandro/imagesloaded |