html forms and liquid designs

Discussion in 'HTML' started by Samuël van Laere, Jun 25, 2003.

  1. Is there a way to have liquid html forms?
    By this i mean that a form should resize
    when the user resizes the browser window
    or changes resolution.

    I set the textarea like this:
    <textarea name="Message" cols="30" rows="10" ></textarea>

    But this isn't any good for an liquid design,
    horizontal scrollbars appear in the browser when resizing
    a page that contains forms with cols and rows set.

    Any toughts?


    --
    Wirh regards,
    Samuël van Laere
    the Netherlands
    www.fortron.net
     
    Samuël van Laere, Jun 25, 2003
    #1
    1. Advertising

  2. Samuël van Laere

    spaghetti Guest

    "Samuël van Laere" <> wrote in message
    news:mglKa.387784$...
    > I set the textarea like this:
    > <textarea name="Message" cols="30" rows="10" ></textarea>
    >
    > But this isn't any good for an liquid design,
    > horizontal scrollbars appear in the browser when resizing
    > a page that contains forms with cols and rows set.


    Just set a style in your stylesheet:

    textarea { width:80%; }

    On all the browsers I've tested this with, it seems to make the "cols"
    attribute not matter, and the text in the text area expands and wraps at the
    edge of the textarea box, not at the column specified. The cols and rows
    attributes are required, which seems pretty weird to me. But whatever. Try
    the above, it should work for what you need.
     
    spaghetti, Jun 25, 2003
    #2
    1. Advertising

  3. "spaghetti" <> schreef in bericht
    news:bdcpit$rkrsd$...
    >
    > "Samuël van Laere" <> wrote in message
    > news:mglKa.387784$...
    > > I set the textarea like this:
    > > <textarea name="Message" cols="30" rows="10" ></textarea>
    > >
    > > But this isn't any good for an liquid design,
    > > horizontal scrollbars appear in the browser when resizing
    > > a page that contains forms with cols and rows set.

    >
    > Just set a style in your stylesheet:
    >
    > textarea { width:80%; }
    >
    > On all the browsers I've tested this with, it seems to make the "cols"
    > attribute not matter, and the text in the text area expands and wraps at

    the
    > edge of the textarea box, not at the column specified. The cols and rows
    > attributes are required, which seems pretty weird to me. But whatever. Try
    > the above, it should work for what you need.
    >
    >


    Thanks a lot Spaghetti,

    Seems to work fine, don't know if its proper use
    but it is the only way and it does the job.
    Perhaps its time that forms and there elements
    start supporting procents as values, next to pixels.


    --
    Wirh regards,
    Samuël van Laere
    the Netherlands
    www.fortron.net
     
    Samuël van Laere, Jun 25, 2003
    #3
  4. Samuël van Laere

    spaghetti Guest

    "Samuël van Laere" <> wrote in message
    news:rYoKa.390337$...
    > Seems to work fine, don't know if its proper use
    > but it is the only way and it does the job.
    > Perhaps its time that forms and there elements
    > start supporting procents as values, next to pixels.


    Elements support all sorts of values: percentage, pixels, points, ems, etc.
    etc.

    The cols and rows attributes in <textarea> are for how many characters.

    Setting the width with percentage in the stylesheet is the proper way. In
    fact, I think cols and rows is silly, but I guess there is a pretty good
    reason.

    Unlike the <q> tag.
     
    spaghetti, Jun 25, 2003
    #4
  5. Samuël van Laere

    combs1945

    Joined:
    Feb 12, 2011
    Messages:
    1
    combs1945, Jun 27, 2011
    #5
    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. Timo Dammes
    Replies:
    2
    Views:
    6,542
    Elliot Schei
    Jun 11, 2004
  2. Sanny
    Replies:
    4
    Views:
    379
    Sanny
    Jul 20, 2007
  3. king kikapu

    Ipc mechanisms and designs.

    king kikapu, Aug 10, 2007, in forum: Python
    Replies:
    3
    Views:
    383
    king kikapu
    Aug 11, 2007
  4. Replies:
    0
    Views:
    533
  5. jenny wilkinson
    Replies:
    0
    Views:
    629
    jenny wilkinson
    Mar 20, 2013
Loading...

Share This Page