IE 6 or other browser

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mysticwater
    New Member
    • Aug 2010
    • 14

    IE 6 or other browser

    Hi,

    I was wonder if it is possible to add an "if...." statement to cover the case of a user using IE 6 or some OTHER terrible browser (my opinion) to go on my site (http://www.rblog.net16 .net/) ?

    Can this be done with HTML coding?

    Thanks.
  • Frinavale
    Recognized Expert Expert
    • Oct 2006
    • 9749

    #2
    HTML is simply a markup language to indicate how the browser should display/render the data. There are no logical statements in HTML (no "if-statements").

    You would have to use JavaScript or you would have to detect which browser was connecting to your server-side code in order to use an "if-statement".

    -Frinny

    Comment

    • JKing
      Recognized Expert Top Contributor
      • Jun 2007
      • 1206

      #3
      There are conditional comments which you can implement. They are most often used to include an IE specific stylesheet.

      Here's a link that explains them Conditional Comments

      Comment

      • Ramil Alcibar
        New Member
        • Sep 2010
        • 10

        #4
        Option 1:
        I would recommend Paul Irish' IE Conditional Comments but take note it's only for IE.

        Option 2:
        Use CSS Hacks - lacks some browser targeting but IE's the only headache, no?

        Option 3:
        Use CSS Browser Selector - you can target almost all browser including its version and even OS. But useless if the user turn off JavaScript. In that case, you can use PHP CSS Browser Selector.

        Comment

        Working...