Facebook Style - textArea height:auto

7 messages Options
Embed this post
Permalink
dirk newbold

Facebook Style - textArea height:auto

Reply Threaded More More options
Print post
Permalink
Hi,

Does anybody know how to achieve an auto increase of the height of a
textArea to fit the input text as the user types, e.g. composing a new
mail or adding a comment in Facebook.

Cheers,

Dirk
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Richard Durr-2

Re: Facebook Style - textArea height:auto

Reply Threaded More More options
Print post
Permalink
I'd suggest you copy the code from facebook... ^^

On Fri, Nov 6, 2009 at 10:30 PM, dirk newbold <[hidden email]> wrote:
Hi,

Does anybody know how to achieve an auto increase of the height of a
textArea to fit the input text as the user types, e.g. composing a new
mail or adding a comment in Facebook.

Cheers,

Dirk
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside


_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Philippe Marschall

Re: Facebook Style - textArea height:auto

Reply Threaded More More options
Print post
Permalink
In reply to this post by dirk newbold
2009/11/6 dirk newbold <[hidden email]>:
> Hi,
>
> Does anybody know how to achieve an auto increase of the height of a
> textArea to fit the input text as the user types, e.g. composing a new
> mail or adding a comment in Facebook.

IIRC there's a JS trick of writing the contents to an invisible div
and giving the text area the same dimensions as the div. As usual, ask
Lukas ;-)

Cheers
Philippe
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
dirk newbold

Re: Facebook Style - textArea height:auto

Reply Threaded More More options
Print post
Permalink
Thanks for the tip.

Lukas, if you happen to spot this one and have a moment I'd be
greatful for any further tips.

Cheers,

Dirk


On Sun, Nov 8, 2009 at 11:08 PM, Philippe Marschall
<[hidden email]> wrote:

> 2009/11/6 dirk newbold <[hidden email]>:
>> Hi,
>>
>> Does anybody know how to achieve an auto increase of the height of a
>> textArea to fit the input text as the user types, e.g. composing a new
>> mail or adding a comment in Facebook.
>
> IIRC there's a JS trick of writing the contents to an invisible div
> and giving the text area the same dimensions as the div. As usual, ask
> Lukas ;-)
>
> Cheers
> Philippe
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Lukas Renggli

Re: Facebook Style - textArea height:auto

Reply Threaded More More options
Print post
Permalink
> Lukas, if you happen to spot this one and have a moment I'd be
> greatful for any further tips.

A few years ago I implemented something like that for the cmsbox, but
luckily there are dozens of plugins available today that do exactly
that. Ask Google for "javascript textarea autosize" and check this
article on Stack Overflow:
<http://stackoverflow.com/questions/7477/autosizing-textarea>.

Lukas

--
Lukas Renggli
http://www.lukas-renggli.ch
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
dirk newbold

Re: Facebook Style - textArea height:auto

Reply Threaded More More options
Print post
Permalink
Thanks

On Mon, Nov 9, 2009 at 8:32 PM, Lukas Renggli <[hidden email]> wrote:

>> Lukas, if you happen to spot this one and have a moment I'd be
>> greatful for any further tips.
>
> A few years ago I implemented something like that for the cmsbox, but
> luckily there are dozens of plugins available today that do exactly
> that. Ask Google for "javascript textarea autosize" and check this
> article on Stack Overflow:
> <http://stackoverflow.com/questions/7477/autosizing-textarea>.
>
> Lukas
>
> --
> Lukas Renggli
> http://www.lukas-renggli.ch
> _______________________________________________
> seaside mailing list
> [hidden email]
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
Miguel Enrique Cobá Martinez

Re: Facebook Style - textArea height:auto

Reply Threaded More More options
Print post
Permalink
In reply to this post by Lukas Renggli
El lun, 09-11-2009 a las 11:32 +0100, Lukas Renggli escribió:

> > Lukas, if you happen to spot this one and have a moment I'd be
> > greatful for any further tips.
>
> A few years ago I implemented something like that for the cmsbox, but
> luckily there are dozens of plugins available today that do exactly
> that. Ask Google for "javascript textarea autosize" and check this
> article on Stack Overflow:
> <http://stackoverflow.com/questions/7477/autosizing-textarea>.
>
> Lukas
>

Cool

--
Miguel Cobá
http://miguel.leugim.com.mx

_______________________________________________
seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside