I can reproduce the effect mentioned by [USER=1705]@Chromaniac[/USER] on a local 2.3.0 Beta 4; image proxy turned off
Within one post:
Image inserted via insert image dialog > URL
BB-Code
[IMG size="192x192"]https://xenforo.com/community/data/avatars/l/11/11388.jpg?1701366656[/IMG]
HTML
[code=html]
<img src="https://xenforo.com/community/data/avatars/l/11/11388.jpg?1701366656" data-url="https://xenforo.com/community/data/avatars/l/11/11388.jpg?1701366656" class="bbImage" data-zoom-target="1" style="" alt="11388.jpg" title="" width="" height="" loading="lazy">
[/code]
Image inserted manually
BB-Code
[img]https://xenforo.com/community/data/avatars/l/11/11388.jpg?1701366656[/img]
HTML
[code=html]
<img src="https://xenforo.com/community/data/avatars/l/11/11388.jpg?1701366656" data-url="https://xenforo.com/community/data/avatars/l/11/11388.jpg?1701366656" class="bbImage" data-zoom-target="1" style="" alt="11388.jpg" title="" width="" height="" loading="lazy">
[/code]
So for images inserted via dialog the [img]
tag has attribute size
- a manually inserted [img]
does not.
In both cases the generated HTML does not have width
/ height
set; this happens because the analyzer code unconditionally sets $this->images[$hash]
, so if an image is used multiple times within the same post and a later usage does not have attribute size
this overwrites the previous value.
If the order is switched (eg. [img]
without size
first followed by [img]
with size
both instances have width
/ height
set in HTML).
IMHO width
/ height
should always be recorded, no matter if the [img]
has attribute size
or not or if the image proxy is enabled or not.