The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript auto font-size reducing in fixed textarea

  • This topic is empty.
Viewing 1 post (of 1 total)
  • Author
  • #206342

    Hey Guys,

    i got a problem. i have a textarea with fixed width and height (750x393px) and large font-size (eg. 100px). if you type in this textarea, the font-size should automatically be reduced so the typed text fits into the textarea. if you delete some chars the font-size should increase.

    you know what i mean? there should be no overflow and no scrollbar. the font-size should decrease or increase, so that the text fits into the textarea.

    this is the basic markup:

    a found a similar script, but this is a div, not a textarea and i dont know how to change this into a textarea:

    and here is a script with a textarea, but the font-size doesnt increase, if i delete some chars:

    can someone help me with that?

Viewing 1 post (of 1 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.