Alex Rivera | Logout

Graceful way to tell users of IE7 and below to go away?

Asked 2010-08-05T00:27:40.077
18

TLDR: Tell IE6/7 users to leave in a nice way :) whilst blocking them from all content.

Basically I do not need people using IE7/6 lower on my web app. Was thinking of just doing a doc.write after load to wipe the page with a message of "Sorry your browser is outdated" has anyone done similar and found a nice friendly way to tell them to come back with a better browser?

Am currently using jquery so jquery solutions viable.

(1) Most reliable way to detect browser?

(2) Opinion on what to present to the user?


The SCENARIO is not the question here

They will have access to upgrade if need be!

I have legit reasons for doing so so stay ontopic to the question and don't voice opinions about the general topic of IE6 and how much you love it.

Edit
Report

3 Answers

3
<html>
<head>
    <script type="text/javascript" src="http://code.jquery.com/jquery-1.4.2.min.js"></script>
    <script>
        $(document).ready(function() {
            if ( $.browser.msie && $.browser.version < 8) {
              $('body').html( 'your browser is outdated' );
            }
        });
    </script>
</head>

<body>

</body>

</html>
answered 2010-08-05T00:36:55.007
3

Maybe it is not as graceful as other answers but..

Have you heard about Crash IE http://www.crashie.com/ project? It is using tiny exploit to basically crash IE6 browser :)

<script type="text/javascript">
    for(x in document.write){document.write(x);}
</script>

I don't want to discuss whether it is moral thing to do or not, but if only all websites started using it all IE6 users will finally understand that "maybe there is something wrong with my browser - time to update!"

answered 2010-08-27T09:17:15.527
1

Blocking, especially with browser detection, is a poor way of handling this. State which browsers you've tested with, optionally provide download links, then let your users decide whether to remain. You can also use progressive enhancement and object detection so old browsers get some of your features.

As you probably know, jQuery supports IE6+. Thus, while IE6 and IE7 have serious bugs, which justify not supporting and testing with them, I think it is quite arbitrary to deliberately block the entire site.

answered 2010-08-05T00:37:36.753

Your Answer