Last modified: 2014-03-20 12:33:36 UTC
It would be useful to be able to access file metadata from Scribunto, particularly the height and width of images. This has already been requested a couple of times on [[Wikipedia:Lua requests]]: * https://en.wikipedia.org/w/index.php?title=Wikipedia:Lua_requests&oldid=567090859#Image_aspect_ratio * https://en.wikipedia.org/wiki/Wikipedia:Lua_requests/Archive_2#File_information Is there any chance of getting a new library to enable this functionality?
Specifically, this will be useful on Wikivoyage, where every main namespace page has a banner image which must have a 7:1 aspect ratio. We need a way to check and tag them automatically for cropping, instead of always checking the file pages one-by-one and doing the math.
I just come here to request the same. I was planning to write some code for automatically creating KML files for georeferencing map images, based on 3 anchor points where user provides latitude and longitude for 3 points on the map. Dimension of the image is one of the elements I would need to have. I was surprised to discover we could not access it. See also this wikitech-l discusion: https://www.mail-archive.com/wikitech-l@lists.wikimedia.org/msg73250.html