Change Input type="text" to Textarea

Discussion in 'HTML' started by Camile, Dec 16, 2005.

  1. Camile

    Camile Guest

    I'm working with a simple form that uses an Input type="text" for a line of
    text limited to a predetermined number of characters. As follows:

    <INPUT TYPE="TEXT" class="text" id="mess" name="messtext" maxlength="100"
    size="60"
    onKeyUp="Count('mess','cntdis','{CHAR} characters left.',160);"><br><span
    id="cntdis" class="smalltext">160 characters left.</span></td>



    I want to convert it to use Textarea so it can be a small square form. I
    can't seem to make my Textarea syntax work in place of the Input
    Type="text".



    <TEXTAREA cols="40" rows="5" id="mess" name="messtext"></textarea>



    The Textarea box displays with the OnKeyup and count(stuff).



    Any suggestions?
    Camile, Dec 16, 2005
    #1
    1. Advertising

  2. Camile

    Camile Guest

    I found a solution at:
    http://www.irt.org/script/1539.htm
    "Camile" <> wrote in message
    news:J_Aof.8906$...
    > I'm working with a simple form that uses an Input type="text" for a line

    of
    > text limited to a predetermined number of characters. As follows:
    >
    > <INPUT TYPE="TEXT" class="text" id="mess" name="messtext" maxlength="100"
    > size="60"
    > onKeyUp="Count('mess','cntdis','{CHAR} characters left.',160);"><br><span
    > id="cntdis" class="smalltext">160 characters left.</span></td>
    >
    >
    >
    > I want to convert it to use Textarea so it can be a small square form. I
    > can't seem to make my Textarea syntax work in place of the Input
    > Type="text".
    >
    >
    >
    > <TEXTAREA cols="40" rows="5" id="mess" name="messtext"></textarea>
    >
    >
    >
    > The Textarea box displays with the OnKeyup and count(stuff).
    >
    >
    >
    > Any suggestions?
    >
    >
    >
    Camile, Dec 16, 2005
    #2
    1. Advertising

  3. "Camile" <> wrote:

    > <TEXTAREA cols="40" rows="5" id="mess" name="messtext"></textarea>


    OK.

    > The Textarea box displays with the OnKeyup and count(stuff).


    Maybe your actual document contains something else than the snippet you
    posted.

    > Any suggestions?


    Post the URL.

    --
    Yucca, http://www.cs.tut.fi/~jkorpela/
    Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html
    Jukka K. Korpela, Dec 16, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Augustus
    Replies:
    1
    Views:
    335
    Ken Schaefer
    Sep 10, 2003
  2. Textarea Inside of a textarea

    , Feb 4, 2006, in forum: ASP General
    Replies:
    6
    Views:
    314
    Anthony Jones
    Feb 5, 2006
  3. Randell D.
    Replies:
    12
    Views:
    243
    Randell D.
    Jul 6, 2005
  4. Vincent van Beveren

    Switich Input field from TYPE=TEXT to TYPE=PASSWORD

    Vincent van Beveren, Jul 13, 2006, in forum: Javascript
    Replies:
    5
    Views:
    166
    Randy Webb
    Jul 13, 2006
  5. Replies:
    1
    Views:
    294
    Bart Van der Donck
    Jul 4, 2007
Loading...

Share This Page