Which IE browser version?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Wade G. Pemberton

    #1

    Which IE browser version?

    Does anyone have a quick script to find which version of IE a page is
    being viewed with?

    Specifically, I want to seperate version 4 from versions 5+, and post a
    warning against using 4.

    I expect I'll have to search out the (navigator.appA gent) string for
    the MSIE substring, but since I don't need it until tomorrow, laziness
    dictates I ask here before getting on with it. Is there another
    variable? a less cumbersome way?

    Thanks in advance.

    Wade

  • Thomas 'PointedEars' Lahn

    #2
    Re: Which IE browser version?

    Wade G. Pemberton wrote:
    [color=blue]
    > Specifically, I want to seperate version 4 from versions 5+, and post a
    > warning against using 4.[/color]

    Before anyone else suggests it: Using the User-Agent header is not
    reliable <http://pointedears.de/scripts/test/whatami>. If know that
    Norton Internet Security modifies, even removes the User-Agent header.

    IE versions below 5.0 do not support the W3C DOM, so this may be one
    indicator. Along with testing for document.all, this should suffice.
    AFAIK Opera implements document.all but it also implements the W3C-DOM.
    I do not know about IE for the Mac, it is likely to be different there.

    Yet the warning should be issued for all IEs below 6.0 SP-1 where many
    security bugs have been fixed.


    HTH

    PointedEars

    Comment

    • kaeli

      #3
      Re: Which IE browser version?

      In article <411B6BEB.3BEAD 3A5@sprynet.com >, w_pemberton@spr ynet.com
      enlightened us with...[color=blue]
      > Does anyone have a quick script to find which version of IE a page is
      > being viewed with?
      >
      > Specifically, I want to seperate version 4 from versions 5+, and post a
      > warning against using 4.
      >[/color]

      Browser detection is usually a big no-no for various reasons, but if you just
      want to distinguish between IE versions, use IE-specific code (ignored by
      other browsers).

      IE conditional comments:
      http://msdn.microsoft.com/workshop/a...omment_ovw.asp

      I don't think too many people use IE4 these days, though.

      --
      --
      ~kaeli~
      All I ask is the chance to prove that money cannot make me
      happy.



      Comment

      • Grant Wagner

        #4
        Re: Which IE browser version?

        Thomas 'PointedEars' Lahn wrote:
        [color=blue]
        > Wade G. Pemberton wrote:
        >[color=green]
        > > Specifically, I want to seperate version 4 from versions 5+, and post a
        > > warning against using 4.[/color]
        >
        > Before anyone else suggests it: Using the User-Agent header is not
        > reliable <http://pointedears.de/scripts/test/whatami>. If know that
        > Norton Internet Security modifies, even removes the User-Agent header.
        >
        > IE versions below 5.0 do not support the W3C DOM, so this may be one
        > indicator. Along with testing for document.all, this should suffice.
        > AFAIK Opera implements document.all but it also implements the W3C-DOM.
        > I do not know about IE for the Mac, it is likely to be different there.
        >
        > Yet the warning should be issued for all IEs below 6.0 SP-1 where many
        > security bugs have been fixed.[/color]

        In addition to what Thomas has said, you may want to consider Conditional
        Comments:

        <url:
        http://msdn.microsoft.com/workshop/a...omment_ovw.asp />

        Yes, it's Internet Explorer only, but after all, you're trying to determine
        IE versions, so it's not a problem that it's a proprietary way of doing that.
        The Conditional Comments and Downlevel-hidden Conditional Comments degrade
        quite nicely. I'm not sure about support for Conditional Comments on the MAC,
        then again, you probably don't want it telling people to upgrade to version 6
        on the MAC since there is no such animal.

        You're probably looking for something like:

        <!--[if lt IE 6]>
        <P>Please upgrade to Internet Explorer 6.</P>
        <![endif]-->
        <![if !lt IE 6]>
        <!-- content intended for IE 6 and other browsers -->
        <![endif]>

        You can probably identify IE 6SP1 more accurately using more specific version
        numbers (<!--[if lt IE 6.0.2800]>). Read "Version Vectors" on the URL I
        provided for more information (and some warnings) about targeting too
        specific a version.

        --
        Grant Wagner <gwagner@agrico reunited.com>
        comp.lang.javas cript FAQ - http://jibbering.com/faq

        Comment

        • Randy Webb

          #5
          Re: Which IE browser version?

          Wade G. Pemberton wrote:
          [color=blue]
          > Does anyone have a quick script to find which version of IE a page is
          > being viewed with?[/color]

          Yes, I have on.
          [color=blue]
          > Specifically, I want to seperate version 4 from versions 5+, and post a
          > warning against using 4.[/color]

          Then do it.

          "If you are using Internet Explorer 4, I (the uninformed web author)
          think its un-advisable for you to use it, even though I have absolutely
          no idea why you use it. Yes, it could be because your computer won't run
          anything better, and if thats the case then I don't want your business
          so I am telling you to use a newer browser"
          [color=blue]
          > I expect I'll have to search out the (navigator.appA gent) string for
          > the MSIE substring, but since I don't need it until tomorrow, laziness
          > dictates I ask here before getting on with it. Is there another
          > variable? a less cumbersome way?[/color]

          navigator.appAg ent?? Did they sneak that one in? I think you are
          referring to the userAgent string (laziness prevents me looking it up).
          As for your solution, since your homework was already due today, my
          laziness (once again) prevents me from copy/pasting the code you need.

          Hint: Read Grant and Kaeli's replies.
          [color=blue]
          > Thanks in advance.[/color]

          You are welcome.

          --
          Randy
          comp.lang.javas cript FAQ - http://jibbering.com/faq

          Comment

          • Wade G. Pemberton

            #6
            Re: Which IE browser version?



            Thomas :
            [color=blue]
            > Before anyone else suggests it: Using the User-Agent header is not
            > reliable <http://pointedears.de/scripts/test/whatami>. If know that
            > Norton Internet Security modifies, even removes the User-Agent header.
            >
            > Yet the warning should be issued for all IEs below 6.0 SP-1 where many
            > security bugs have been fixed.[/color]

            I'm not doing anything so dramatic as warning people about security issues.

            I'm using some inline styles to display photos, titles, atl tags,
            descriptions etc in one viewing area, and want to warn folks with really old
            browsers that the page will blow up if they push the buttons. Netscape 4.x
            is easy to detect, and give a warning. I'm not sure there are too many IE
            4.0's out there, but they're worse in terms of supporting dynamics, so I
            decided to add a warning for them. It's just an afterthought, and I was
            curious to see if anyone had rendered a quick script that split IE4.0 from
            IE 5.0 and ff. ( MS insists they're all 4.0 in response to the simplistic
            versionApp query).

            I don't care if they are all insecure, don't care if they are smart enough to
            spoof the sniffer (since that means they're not likely too old), and am not
            really looking for the ultimate sniffer. Just one line the effectively
            splits 4.0 from 5.0.

            However, I did read your references, which served to catch me up on an area
            I'd not paid much attention to in recent months/years. Thanks for the
            time.


            Wade


            Comment

            • Thomas 'PointedEars' Lahn

              #7
              Re: Which IE browser version?

              Wade G. Pemberton wrote:
              [color=blue]
              > Thomas :[/color]

              Instead of a personal salutation which is quite nonsensical in a m:n medium
              like NetNews, you should have provided a short attribution line so that the
              quoted text can be assigned to its respective author without looking up the
              thread structure (if still available).
              [color=blue][color=green]
              >> Before anyone else suggests it: Using the User-Agent header is not
              >> reliable <http://pointedears.de/scripts/test/whatami>. If know that
              >> Norton Internet Security modifies, even removes the User-Agent header.
              >>
              >> Yet the warning should be issued for all IEs below 6.0 SP-1 where many
              >> security bugs have been fixed.[/color]
              >
              > I'm not doing anything so dramatic as warning people about security
              > issues.[/color]

              Then you should refrain from annoying your users like this.
              [color=blue]
              > I'm using some inline styles to display photos, titles, atl tags,
              > descriptions etc in one viewing area, and want to warn folks with
              > really old browsers that the page will blow up if they push the
              > buttons.[/color]

              If they deliberately chose a buggy browser, let them.
              [color=blue]
              > Netscape 4.x is easy to detect,[/color]

              Is it really?
              [color=blue]
              > and give a warning. I'm not sure there are too many
              > IE 4.0's out there, but they're worse in terms of supporting dynamics, so
              > I decided to add a warning for them.[/color]

              Instead of pursuing such a nonsense you should pursue a solution of
              graceful degradation as often discussed in this newsgroup. Especially
              CSS provides quite easy ways to do so:

              <http://www.w3developme nt.de/css/hide_css_from_b rowsers/>
              [color=blue]
              > It's just an afterthought, and I was curious to see if anyone had
              > rendered a quick script that split IE4.0 from IE 5.0 and ff. ( MS[/color]
              insists they're all 4.0 in response to the simplistic versionApp query).

              It is because they are in a sense on the level of Mozilla/4.0. Because
              historically evolved, most of the User-Agent header of Web browsers,
              especially the navigator.appNa me and navigator.appNa me components, has
              become meaningless.


              PointedEars

              Comment

              • Thomas 'PointedEars' Lahn

                #8
                Re: Which IE browser version?

                Wade G. Pemberton wrote:
                [color=blue]
                > Thomas :[/color]

                Instead of a personal salutation which is quite nonsensical in a m:n medium
                like NetNews, you should have provided a short attribution line so that the
                quoted text can be assigned to its respective author without looking up the
                thread structure (if still available).
                [color=blue][color=green]
                >> Before anyone else suggests it: Using the User-Agent header is not
                >> reliable <http://pointedears.de/scripts/test/whatami>. If know that
                >> Norton Internet Security modifies, even removes the User-Agent header.
                >>
                >> Yet the warning should be issued for all IEs below 6.0 SP-1 where many
                >> security bugs have been fixed.[/color]
                >
                > I'm not doing anything so dramatic as warning people about security
                > issues.[/color]

                Then you should refrain from annoying your users like this.
                [color=blue]
                > I'm using some inline styles to display photos, titles, atl tags,
                > descriptions etc in one viewing area, and want to warn folks with
                > really old browsers that the page will blow up if they push the
                > buttons.[/color]

                If they deliberately chose a buggy browser, let them.
                [color=blue]
                > Netscape 4.x is easy to detect,[/color]

                Is it really?
                [color=blue]
                > and give a warning. I'm not sure there are too many
                > IE 4.0's out there, but they're worse in terms of supporting dynamics, so
                > I decided to add a warning for them.[/color]

                Instead of pursuing such a nonsense you should pursue a solution of
                graceful degradation as often discussed in this newsgroup. Especially
                CSS provides quite easy ways to do so:

                <http://www.w3developme nt.de/css/hide_css_from_b rowsers/>
                [color=blue]
                > It's just an afterthought, and I was curious to see if anyone had
                > rendered a quick script that split IE4.0 from IE 5.0 and ff. ( MS
                > insists they're all 4.0 in response to the simplistic versionApp query).[/color]

                It is because they are in a sense on the level of Mozilla/4.0. Because
                historically evolved, most of the User-Agent header of Web browsers,
                especially the navigator.appNa me and navigator.appVe rsion components,
                has become meaningless.


                PointedEars

                Comment

                • Randy Webb

                  #9
                  Re: Which IE browser version?

                  Thomas 'PointedEars' Lahn wrote:
                  [color=blue]
                  > Wade G. Pemberton wrote:
                  >
                  >[color=green]
                  >>Thomas :[/color]
                  >
                  >
                  > Instead of a personal salutation which is quite nonsensical in a m:n medium
                  > like NetNews, you should have provided a short attribution line so that the
                  > quoted text can be assigned to its respective author without looking up the
                  > thread structure (if still available).
                  >[/color]

                  If they over-attribute, you whine. If they under-attribute, you whine.

                  Are you actually as anally retentive as you act?

                  [color=blue][color=green][color=darkred]
                  >>>Before anyone else suggests it: Using the User-Agent header is not
                  >>>reliable <http://pointedears.de/scripts/test/whatami>. If know that
                  >>>Norton Internet Security modifies, even removes the User-Agent header.
                  >>>
                  >>>Yet the warning should be issued for all IEs below 6.0 SP-1 where many
                  >>>security bugs have been fixed.[/color]
                  >>
                  >>I'm not doing anything so dramatic as warning people about security
                  >>issues.[/color]
                  >
                  >
                  > Then you should refrain from annoying your users like this.
                  >[/color]

                  You must be.
                  [color=blue]
                  >[color=green]
                  >>I'm using some inline styles to display photos, titles, atl tags,
                  >>description s etc in one viewing area, and want to warn folks with
                  >>really old browsers that the page will blow up if they push the
                  >>buttons.[/color]
                  >
                  >
                  > If they deliberately chose a buggy browser, let them.[/color]

                  You are making the unfounded assumption that they have a "choice" about
                  the browser. You really should learn to read up on things before you
                  babble incoherently about things.
                  [color=blue]
                  >[color=green]
                  >>Netscape 4.x is easy to detect,[/color]
                  >
                  >
                  > Is it really?[/color]

                  Yes, it is quite easy actually.
                  [color=blue]
                  >[color=green]
                  >>and give a warning. I'm not sure there are too many
                  >>IE 4.0's out there, but they're worse in terms of supporting dynamics, so
                  >>I decided to add a warning for them.[/color]
                  >
                  >
                  > Instead of pursuing such a nonsense you should pursue a solution of
                  > graceful degradation as often discussed in this newsgroup. Especially
                  > CSS provides quite easy ways to do so:
                  >
                  > <http://www.w3developme nt.de/css/hide_css_from_b rowsers/>[/color]

                  You really are as stupid as you act. The only reason you have not joined
                  George in the trash-can is because I don't want innocent people
                  believing your garbage nonsense.

                  Also, you should check into your User Agent for News, it seems to be
                  quite adept at double-posting articles. In the event you do it to make
                  sure they read it twice, I can almost guarantee that if they don't
                  comprehend your babble the first time, reading it twice won't help them.

                  --
                  Randy
                  comp.lang.javas cript FAQ - http://jibbering.com/faq

                  Comment

                  • Thomas 'PointedEars' Lahn

                    #10
                    Re: Which IE browser version?

                    Randy Webb wrote:
                    [color=blue]
                    > Thomas 'PointedEars' Lahn wrote:[color=green]
                    >> Wade G. Pemberton wrote:
                    >> [...][color=darkred]
                    >>>I'm using some inline styles to display photos, titles, atl tags,
                    >>>descriptio ns etc in one viewing area, and want to warn folks with
                    >>>really old browsers that the page will blow up if they push the
                    >>>buttons.[/color]
                    >>
                    >> If they deliberately chose a buggy browser, let them.[/color]
                    >
                    > You are making the unfounded assumption that they have a "choice" about
                    > the browser. [...][/color]

                    If they don't have the choice, telling them that something else is
                    better does not help either. For the rest of your posting, I have
                    had enough of your "style" for the next month.


                    PointedEars

                    Comment

                    • Wade G. Pemberton

                      #11
                      Re: Which IE browser version?



                      [color=blue]
                      > Then you should refrain from annoying your users like this.
                      > <snip>[/color]

                      Posting your response twice to the newsgroup may be at least equally
                      annoying.....

                      Your most recent posting(s) brought to mind a reference frequently used by
                      many discussion groups. Everyone should visit at least once. With some
                      research, one can usually find examples of each type in any forum.



                      Mike's been doing this page since Netscape 2.0, methinks. It's still valid.


                      Wade

                      Comment

                      • Thomas 'PointedEars' Lahn

                        #12
                        Re: Which IE browser version?

                        Wade G. Pemberton wrote:

                        Who wrote this? <http://www.netmeister. org/news/learn2quote.htm l>
                        vvvvvvvvvvvvvvv[color=blue][color=green]
                        >> Then you should refrain from annoying your users like this.
                        >> <snip>[/color]
                        >
                        > Posting your response twice to the newsgroup may be at least equally
                        > annoying.....[/color]

                        You may want to get informed about Supersedes and newsgroups in general.
                        [color=blue]
                        > http://www.winternet.com/~mikelr/flame1.html
                        >
                        > Mike's been doing this page since Netscape 2.0, methinks. It's still
                        > valid.[/color]

                        It is not ;-)
                        <http://validator.w3.or g/check?uri=http://www.winternet.c om/~mikelr/flame1.html&ss= 1;verbose=1>

                        BTW: It was advice, not a flame. If you are so insecure to read advice
                        as a flame, NetNews may be not the appropriate medium for you to use.


                        F'up2 poster

                        PointedEars

                        Comment

                        • kaeli

                          #13
                          Re: Which IE browser version?

                          In article <411BCF6A.7F560 10A@sprynet.com >, w_pemberton@spr ynet.com
                          enlightened us with...[color=blue]
                          >
                          > I'm using some inline styles to display photos, titles, atl tags,
                          > descriptions etc in one viewing area, and want to warn folks with really old
                          > browsers that the page will blow up if they push the buttons.[/color]

                          Um, if you coded the functions that are called when users click buttons in a
                          way that degraded nicer, the page wouldn't blow up in older browsers.
                          Are you using object detection before you go using the objects?

                          --
                          --
                          ~kaeli~
                          If it's tourist season, why can't we shoot them?



                          Comment

                          Working...