views:

402

answers:

2

Chrome makes textareas resizable by default. How can I attach events to the resizing events for the textareas ? Doing the naive $('textarea').resize(function(){...}) does nothing.

+3  A: 

I can't test this right now, but according to this forum entry it can be disabled using:

style="resize: none;"

unlike stated in that entry, max-width and max-height won't cut it - thanks to @Jonathan Sampson for the info.

Pekka
+1 `resize:none` disables it. `max-width` and `max-height` didn't: http://jsbin.com/inane
Jonathan Sampson
Cheers Jonathan. I updated my answer accordingly.
Pekka
+1  A: 

It doesn't look like you can specifically attach events to resizing a textarea. The resize event fires when the window is resized.

eliah