That javascript, in its current format, would be quite difficult to implement.
I wonder if it could be simplified...
<img src="http://shoutbox.menthix.net/images/bunny.jpg" onload="this.width=this.width*(percentage/100);">
Of course, onload is dodgy... it doesn't always work for avatar resizing, which means it won't always work for this.