I have piece of javascript code, which should process when the browser window is resized.
resize.style.marginRight=(resize.offsetWidth-$(this)[0].offsetWidth)+'px'
Tryed this stuff (doesn't work):
window.onresize = function(event) {
resize.style.marginRight=(resize.offsetWidth-$(this)[0].offsetWidth)+'px'
}
Full code available - http://jsbin.com/adelu3/2/ (see page source)
Html (generated by the script):
<div class="resizable-textarea">
<span>
<textarea class="resizable processed" cols="" rows=""></textarea>
<div class="resize"></div>
</span>
</div>
Thanks.