Setting textbox width for Netscape 4.7

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jeff Nibler

    Setting textbox width for Netscape 4.7

    I'm trying to set the width of a textbox via a style sheet but it isn't working for Netscape 4.7

    This is what the page looks like:
    <form>
    <input type="text" class="t1">
    </form>


    This is what the style sheet looks like:

    ..t1 {
    width: 15;
    }


    It works in IE and Netscape 7 but not in Netscape 4. In NS4, it appears that the "width" property of a textbox doesn't work at all.... you have to use "size". I tried using "size" in the style sheet but it doesn't work.

    Any advice would be greatly appreciated. Thanks!

    --
    Jeff Nibler
  • David Dorward

    #2
    Re: Setting textbox width for Netscape 4.7

    Jeff Nibler wrote:[color=blue]
    > This is what the style sheet looks like:
    >
    > .t1 {
    > width: 15;
    > }[/color]

    15 what? Units are required for non-zero lengths.

    <http://diveintomark.or g/archives/2003/05/05/why_we_wont_hel p_you>
    [color=blue]
    > It works in IE and Netscape 7 but not in Netscape 4.[/color]

    Netscape 4 is a browser with tiny market share and very poor support for
    CSS. Many (probably most) authors who use CSS don't worry about the
    appearance in NS4 and use the multiple media type or @import hack to hide
    the styles from that browser.

    --
    David Dorward <http://blog.dorward.me .uk/> <http://dorward.me.uk/>
    Home is where the ~/.bashrc is

    Comment

    • Steve Pugh

      #3
      Re: Setting textbox width for Netscape 4.7

      "Jeff Nibler" <djnibler@spa m-me-not-hotmail.com> wrote:
      [color=blue]
      >I'm trying to set the width of a textbox via a style sheet but it isn't working for Netscape 4.7[/color]

      Netscape 4 has very poor CSS support. It supports virtually no styles
      at all on input elements. And it frequently screws up what few styles
      it does try to support.
      [color=blue]
      >.t1 {
      > width: 15;
      >}[/color]

      All non-zero lengths must have units.
      [color=blue]
      > I tried using "size" in the style sheet but it doesn't work.[/color]

      Of course not, size isn't a CSS property.

      Best advice is to stop worrying about NN4 and let your pages go
      unstyled in that relic.

      Steve

      --
      "My theories appal you, my heresies outrage you,
      I never answer letters and you don't like my tie." - The Doctor

      Steve Pugh <steve@pugh.net > <http://steve.pugh.net/>

      Comment

      • Jeff Nibler

        #4
        Re: Setting textbox width for Netscape 4.7

        Thanks for the reply. Unfortunately, I am forced (by clients) to write this
        site with Netscape 4.7 in mind. For some reason, many of our clients still
        use Netscape 4.7 in their operations and absolutely refuse to upgrade to
        newer versions even though it is free to do so.

        As for units... it doesn't matter. I have tried width: 15px; but that
        doesn't work either.

        --
        Jeff Nibler



        "David Dorward" <dorward@yahoo. com> wrote in message
        news:cf8l5f$h94 $1$830fa79f@new s.demon.co.uk.. .[color=blue]
        > Jeff Nibler wrote:[color=green]
        > > This is what the style sheet looks like:
        > >
        > > .t1 {
        > > width: 15;
        > > }[/color]
        >
        > 15 what? Units are required for non-zero lengths.
        >
        > <http://diveintomark.or g/archives/2003/05/05/why_we_wont_hel p_you>
        >[color=green]
        > > It works in IE and Netscape 7 but not in Netscape 4.[/color]
        >
        > Netscape 4 is a browser with tiny market share and very poor support for
        > CSS. Many (probably most) authors who use CSS don't worry about the
        > appearance in NS4 and use the multiple media type or @import hack to hide
        > the styles from that browser.
        >
        > --
        > David Dorward <http://blog.dorward.me .uk/> <http://dorward.me.uk/>
        > Home is where the ~/.bashrc is[/color]


        Comment

        • Neal

          #5
          Re: Setting textbox width for Netscape 4.7

          On Mon, 9 Aug 2004 13:22:44 -0700, Jeff Nibler
          <djnibler@spa m-me-not-hotmail.com> wrote:
          [color=blue]
          > Thanks for the reply. Unfortunately, I am forced (by clients) to write
          > this
          > site with Netscape 4.7 in mind. For some reason, many of our clients
          > still
          > use Netscape 4.7 in their operations and absolutely refuse to upgrade to
          > newer versions even though it is free to do so.
          >
          > As for units... it doesn't matter. I have tried width: 15px; but that
          > doesn't work either.
          >[/color]


          Please don't put quoted material in a signature.

          Tell them that the only way to support modern browsers AND NN4 is to set
          up separate stylesheets and that's going to double the cost. Because
          that's exactly what you'll have to do here.

          Comment

          • kchayka

            #6
            Re: Setting textbox width for Netscape 4.7

            Jeff Nibler wrote:[color=blue]
            > Unfortunately, I am forced (by clients) to write this
            > site with Netscape 4.7 in mind.[/color]

            Then you should forget about trying to use much CSS, since NS 4.x has
            rather limited CSS support, and what it *does* support tends to be buggy.

            --
            Reply email address is a bottomless spam bucket.
            Please reply to the group so everyone can share.

            Comment

            • Spartanicus

              #7
              Re: Setting textbox width for Netscape 4.7

              "Jeff Nibler" <djnibler@spa m-me-not-hotmail.com> wrote:

              Please don't top post in this group [manually corrected this once] and
              trim down the quoted bit to the minimum required. Only your sig should
              follow your sig delimiter, quoting below a sig delimiter screws up other
              people's ability to follow up properly.
              [color=blue]
              > Netscape 4 is a browser with tiny market share and very poor support for
              > CSS. Many (probably most) authors who use CSS don't worry about the
              > appearance in NS4 and use the multiple media type or @import hack to hide
              > the styles from that browser.[/color]
              [color=blue]
              >Thanks for the reply. Unfortunately, I am forced (by clients) to write this
              >site with Netscape 4.7 in mind.[/color]

              That doesn't mean that you have to give NS4 users styled content.
              Properly marked up content sans styling will work fine for NS4 users.
              Educate your client if they have a problem with that. If that fails,
              consider not using CSS at all and create a tag soup site.
              [color=blue]
              >As for units... it doesn't matter. I have tried width: 15px; but that
              >doesn't work either.[/color]

              It does matter, even though it may not solve your immediate problem.

              --
              Spartanicus

              Comment

              • Alan J. Flavell

                #8
                Re: Setting textbox width for Netscape 4.7

                On Mon, 9 Aug 2004, Jeff Nibler wrote:
                [color=blue]
                > Thanks for the reply.[/color]

                Those who are genuinely grateful show their thanks by taking advice,
                and even sometimes repaying the compliment by passing it on to others.
                [color=blue]
                > Unfortunately, I am forced (by clients) to write this
                > site with Netscape 4.7 in mind.[/color]

                I think we all have NN4.* "in mind". Sometimes, it's just not capable
                of the more interesting parts of stylesheets, but that doesn't
                necessarily mean you can't make content accessible (and, within
                certain limits, even cosmetically attractive) if you put your mind to
                it (and charge your customer accordingly, natch).
                [color=blue]
                > As for units... it doesn't matter.[/color]

                OH YES IT DOES...

                Any client which does anything other than to ignore a non-zero value
                without units is in a State of Sin as far as CSS is concerned. So if
                it ever does what you want, it's a bug - and that's official.
                [color=blue]
                > I have tried width: 15px; but that doesn't work either.[/color]

                "doesn't work"? There's a lot of that about nowadays: lounging around
                on the couch, drinking beer and watching TV all day.

                Which is just a way of saying "don't you realise you just triggered a
                standard response"? I recommend perusal of


                In this case, especially


                good luck

                Comment

                • Jeff Nibler

                  #9
                  Re: Setting textbox width for Netscape 4.7

                  "Neal" <neal413@yahoo. com> wrote in message
                  news:opschh9ic2 6v6656@news.ind ividual.net...[color=blue]
                  > On Mon, 9 Aug 2004 13:22:44 -0700, Jeff Nibler
                  > Tell them that the only way to support modern browsers AND NN4 is to set
                  > up separate stylesheets and that's going to double the cost. Because
                  > that's exactly what you'll have to do here.[/color]


                  That is exactly what I am trying to do. I have a js include (on each page)
                  that detects the browser version, then uses document.write to write the link
                  to the appropriate style sheet. The problem is that I cannot find a way to
                  set the width of a textbox in a style sheet for Nestscape 4.7. I've been
                  searching the web and usenet archives all day and am finding that Netscape
                  4.7 doesn't support any size/width attributes in CSS for a textbox. It is
                  looking like the only way around this is create two completely separate
                  pages; one for NS4 and one for all others. The NS4 page will have it's
                  textbox widths set via the "size" property directly on the page, and the
                  other version of the page will use a CSS. I will use ASP, CGI, or JavaScript
                  to automatically detect their browser version and display the appropriate
                  page. It is ridiculous, but I can't find any other way to accomplish the
                  desired result.

                  I hear a lot of people saying how obsolete Netscape 4.7 is, but you would
                  not believe how many large corporations still use it (especially for
                  intranets) and refuse to upgrade to a newer browser. The issue for many of
                  them is that their IS department would need to handle the roll-out which can
                  cost a lot of money depending on the size of the organization.



                  Comment

                  • Jeff Nibler

                    #10
                    Re: Setting textbox width for Netscape 4.7

                    "Alan J. Flavell" <flavell@ph.gla .ac.uk> wrote in message
                    news:Pine.LNX.4 .61.04080922312 70.16891@ppepc5 6.ph.gla.ac.uk. ..[color=blue][color=green]
                    > > As for units... it doesn't matter.[/color]
                    >
                    > OH YES IT DOES...
                    >
                    > Any client which does anything other than to ignore a non-zero value
                    > without units is in a State of Sin as far as CSS is concerned. So if
                    > it ever does what you want, it's a bug - and that's official.[color=green]
                    > > I have tried width: 15px; but that doesn't work either.[/color]
                    >
                    > "doesn't work"? There's a lot of that about nowadays: lounging around
                    > on the couch, drinking beer and watching TV all day.
                    >
                    > Which is just a way of saying "don't you realise you just triggered a
                    > standard response"? I recommend perusal of
                    > http://www.catb.org/~esr/faqs/smart-questions.html
                    >
                    > In this case, especially
                    > http://www.catb.org/~esr/faqs/smart-...html#id2888580[/color]

                    When I said "it doesn't matter" and "doesn't work," I was referring to the
                    specific behavior I am experiencing with Netscape 4.7. Your links refer to
                    someone who asks a question with no information. If you read my original
                    question, you would understand that in my reply, "doesn't work" means
                    "Netscape doesn't change the width of a text box when I use width: 15 and it
                    ALSO doesn't change the width of the textbox when I use width: 15px," which
                    is what I meant by "doesn't matter." If I had said, "it doesn't work"
                    without first giving a detailed explanation (in my original post), then I
                    would understand your flame. But thanks anyway.

                    Jeff




                    Comment

                    • Andrew Thompson

                      #11
                      Re: Setting textbox width for Netscape 4.7

                      On Mon, 9 Aug 2004 22:41:17 +0100, Alan J. Flavell wrote:

                      ('doesn't work')[color=blue]
                      > http://www.catb.org/~esr/faqs/smart-...html#id2888580[/color]

                      They missed my favorite response!
                      "Flog it with a whip".. ;-)

                      --
                      Andrew Thompson
                      http://www.PhySci.org/ Open-source software suite
                      http://www.PhySci.org/codes/ Web & IT Help
                      http://www.1point1C.org/ Science & Technology

                      Comment

                      • Andrew Thompson

                        #12
                        Re: Setting textbox width for Netscape 4.7

                        On Mon, 9 Aug 2004 15:05:45 -0700, Jeff Nibler wrote:
                        [color=blue]
                        > That is exactly what I am trying to do. I have a js include (on each page)
                        > that detects the browser version,[/color]

                        This is a bad way to go. JS gurus generally advocate
                        'object/feature detection' to ascertain what can and
                        cannot be done in a particular browser, but..
                        [color=blue]
                        >..then uses document.write to write the link
                        > to the appropriate style sheet.[/color]

                        This is better handled using pure CSS/HTML..

                        <link rel="...." type='text/css'>

                        ...can be read by old IE and NN, whereas..

                        <style type='text/css'>
                        @import ...
                        </style>

                        ...will be completely ignored ny the old browsers.

                        HTH

                        --
                        Andrew Thompson
                        http://www.PhySci.org/ Open-source software suite
                        http://www.PhySci.org/codes/ Web & IT Help
                        http://www.1point1C.org/ Science & Technology

                        Comment

                        • Andrew Thompson

                          #13
                          Re: Setting textbox width for Netscape 4.7

                          On Mon, 9 Aug 2004 15:17:48 -0700, Jeff Nibler wrote:
                          [color=blue]
                          > If I had said, "it doesn't work"
                          > without first giving a detailed explanation (in my original post),[/color]

                          Which readers of later posts may not have access to..

                          Whereas if you'd said "it doesn't resize",
                          everybody has a chance of being on the same
                          page.
                          [color=blue]
                          >..then I
                          > would understand your flame.[/color]

                          (chuckles) You'll know a flame when
                          your ass is smoldering..
                          [color=blue]
                          >..But thanks anyway.[/color]

                          But feel free to give a back-hand response that
                          indicates you are 'so much better' than the
                          person who'm you perceive to have slighted you.

                          <dripping with..>
                          I'm sure everybody will be convinced..
                          </dripping with..> ;-)

                          --
                          Andrew Thompson
                          http://www.PhySci.org/ Open-source software suite
                          http://www.PhySci.org/codes/ Web & IT Help
                          http://www.1point1C.org/ Science & Technology

                          Comment

                          • Jan Roland Eriksson

                            #14
                            Re: Setting textbox width for Netscape 4.7

                            On Mon, 9 Aug 2004 15:05:45 -0700, "Jeff Nibler"
                            <djnibler@spa m-me-not-hotmail.com> wrote:
                            [color=blue]
                            >"Neal" <neal413@yahoo. com> wrote in message
                            >news:opschh9ic 26v6656@news.in dividual.net...[color=green]
                            >> Tell them that the only way to support modern browsers AND
                            >> NN4 is to set up separate stylesheets and that's going to
                            >> double the cost. Because that's exactly what you'll have to do here.[/color]
                            >
                            >That is exactly what I am trying to do. I have a js include...
                            >that detects the browser version...[/color]

                            Bad move; stay on CSS only and read up on the @import directive.
                            (see Andrews post below for details)

                            You may also want to read the following article...

                            <http://www.css.nu/articles/About-JSSS.html>

                            ....and make sure to follow the link to 'JSSS'.

                            A full understanding of what 'JSSS' has to "offer" as specified, will
                            also tell you what level of CSS that NS4x browsers can handle so don't
                            expect much luck with styling for form elements as it is.

                            Anyway; and this is just a silly idea, if you can find a way to have all
                            other browsers but NS4x to ignore a 'JSSS' style sheet, you could write
                            one to be served specifically for NS4x, it would work as a fact :-)

                            --
                            Rex


                            Comment

                            • Jan Roland Eriksson

                              #15
                              Re: Setting textbox width for Netscape 4.7

                              On Mon, 09 Aug 2004 22:58:01 GMT, Andrew Thompson
                              <SeeMySites@www .invalid> wrote:
                              [color=blue]
                              >On Mon, 9 Aug 2004 15:05:45 -0700, Jeff Nibler wrote:[/color]
                              [...][color=blue][color=green]
                              >>..then uses document.write to write the link
                              >> to the appropriate style sheet.[/color]
                              >
                              >This is better handled using pure CSS/HTML..
                              >
                              ><link rel="...." type='text/css'>
                              >
                              >..can be read by old IE and NN, whereas..
                              >
                              ><style type='text/css'>
                              >@import ...
                              ></style>
                              >
                              >..will be completely ignored ny the old browsers.[/color]

                              While what you say is completely true of course, I would still recommend
                              that the @import directive should be a part of the linked external style
                              sheet.

                              The STYLE element is in reality not a good design, after all we are
                              supposed to keep markup and presentational suggestions as separate
                              resources.

                              --
                              Rex


                              Comment

                              Working...