Topic on Project:Support desk

Set object to Thumbnail Size Preference

2
Summary by PlavorSeol

Answered - solution in the answer

Jer Hughes (talkcontribs)

Can I set a DIV's width to the user's "Thumbnail size" preference?

Something like:

<div style="width:{{thumbsize}}"></div>
MarkAHershberger (talkcontribs)

From what I've found, you would have to use JS for this.

thumbsize = mw.user.options.get( 'thumbsize' );

thumbsize would then be index into the PHP variable $wgThumbLimits.