![]() Topic: Help cobbling JS for open win > image fit (Page 1 of 1) |
|
---|---|
Maniac (V) Mad Scientist From: |
![]() JS is definitely not my strong suit. I can cobble some simple scripts together with some trial-n-error. That's what I'm doing right now, but I would like some help to expediate matters. |
Maniac (V) Mad Scientist From: |
![]()
|
Paranoid (IV) Inmate From: A graveyard of dreams |
![]() I had no problem grabbing the size of an image using document.getElementById["name"].width or document.getElementById["name"].height. You just have to make sure that the images are loaded before trying to get the dimensions. Doesn't that method work for you? |
Maniac (V) Mad Scientist with Finglongers From: Cell 53, East Wing |
![]() You really need the size of the full image before it is loaded which is tricky. |