Results 1 to 4 of 4

Thread: HTML: resizing a file input

  1. #1

    Thread Starter
    Evil Genius alex_read's Avatar
    Join Date
    May 2000
    Location
    Espoo, Finland
    Posts
    5,538

    HTML: resizing a file input

    The following code works in IE & resizes the file input element to be the width of the table cell containing it, can anyone tell me how I can modify this to work within netscape/mozilla please?
    Code:
    <TD Width="100%">
        <input type="file" id="test1" style="width:100%">
    </TD>

    Please rate this post if it was useful for you!
    Please try to search before creating a new post,
    Please format code using [ code ][ /code ], and
    Post sample code, error details & problem details

  2. #2
    Frenzied Member vbNeo's Avatar
    Join Date
    May 2002
    Location
    Jutland, Denmark
    Posts
    1,994
    AFAIK that's valid CSS - did you test it in the Gecko engine ?
    "Lies, sanctions, and cruise missiles have never created a free and just society. Only everyday people can do that."
    - Zack de la Rocha


    Hear me roar.

  3. #3
    Addicted Member
    Join Date
    Sep 2002
    Location
    Durham, NC, US
    Posts
    218
    Neo is right. Furthermore, you can't, and should not attempt to, change the size of form controls. It undermines accessibility and posses a security risk.
    Travis, Kung Foo Journeyman

    Web Standards: HTML 4.01, CSS Level 2, ECMA 262 Bindings to DOM Level 1, JavaScript 1.5 Guide and Reference
    Perl: Documentation, Learn Perl, Llama, Camel, Cookbook, Perl Monks, Perl Mongers, O'Reilly's Perl.com, ActiveState, CPAN, TPJ, and use Perl;
    OSS: Mozilla, MySQL (Manual)

  4. #4
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    Mozilla refuses to style the file input control in any way. This is intentional.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width