onload="javascript:this.style.width=50;this.style.height= 50 November 25, 2008 7:54 PM   Subscribe

MeFiHTML: Is there a reason to first set profile images to width & height = 0, then set the actual size via javascript?

The final effect is that the page loads, then all of a sudden shifts 50px to the right as the images widths are set. Is this by design? Wouldn't it make more sense to just set the real size in the first place?

The code under consideration:

[img style="border: 1px solid gray; padding: 1px; float: left; clear: left; position: relative; bottom: 55px; margin-right: 5px; width: 50px; height: 50px;" onload="javascript:this.style.width=50;this.style.height= 50;" onerror='this.src="http://images.metafilter.com/mefi/userphoto.png";' src="http://images.metafilter.com/mefi/userphoto.png" width="0" height="0"]
posted by signal to MetaFilter-Related at 7:54 PM (6 comments total)

I'll take a look. Where is this happening?
posted by pb (staff) at 8:06 PM on November 25, 2008


For me, on every page. It loads, them BUMP. Using FF3.0.4
posted by signal at 8:10 PM on November 25, 2008


¯\_(0_o)_/¯
posted by turgid dahlia at 8:13 PM on November 25, 2008 [9 favorites]


Every page? I'm guessing you have that profile image Greasemonkey script installed that was posted a while back. Try disabling Greasemonkey to verify.

If the images are gone when you have Greasemonkey disabled, then that's why you're seeing profile images on every page. You'll have to contact the author of that script to change it.
posted by pb (staff) at 8:14 PM on November 25, 2008


D'oh.

Please close.
posted by signal at 8:23 PM on November 25, 2008


Sure, no problem. Here's the original thread about that script if you need it.
posted by pb (staff) at 8:35 PM on November 25, 2008


« Older Chicagoans: 2008-12-03   |   A Page for Job Seekers, Please Newer »

This thread is closed to new comments.