Purposes of the Goodbye IE6 project

The purpose of project is to stimulate users of the internet to use new software.

Site which were optimized for old browsers become bigger and slower due to additional verifications and corrections in scripts.

Therefore we offer all interested persons to join our project and to use in their sites script which will verify browser version, and will offer to download newer version if visitor's browser is old.

How does it work?

A first we add script BrowserCompatible.js to the sitr source. After, we call function check(), script cheks browser's name and version. Then it compares information to the array of compatible versions. If browsers version is not compatible, warning is automatically created and shows to user. Here is an example.

I've made some fixes

Due to pretty big number of mail from people using GoodBye IE6, I've made some fixes to the script:

1. Replaced English translation with the better one (thx David Russell).
2. Add Dutch translation (thx Eelke Blok).
3. Add black list: now you can choose make list of allowed browsers or list of disallowed browsers (thx Eelke Blok).
4. Add customization feature that allow to set own background image and cancel button image (thx Raffaele Rasini).
5. Fix bug with Chrome compatible and add Chrome 1 to default compatible and offered lists (thx Phil Allum).

How to add browser verification?

It's very simple to add verification on your site. Just generate code with your settings and copy it to your site.

Below you can read the principles of work of the script.

<script src="http://www.goodbyeie6.org.ua/BrowserCompatible.js" type="text/javascript" > </script >

This will link the script BrowserCompatible.js to the site. Of course, you can download the script, but we recommend to use it from http://www.goodbyeie6.org.ua/, as here it will be corrected and improved.

To start browser check which will display warning message, you have to call the next function:

BrowserCompatible.check();

The best way to call this function is after page loaded. Here are three ways to insert it.

1. The simplest.

<script type="text/javascript" >
      BrowserCompatible.check();
</script >

You have to insert this code before a closing tag </body>.

2. On event onload.

<body onload="BrowserCompatible.check()" >

If you have a possibility, add to the tag <body> the attribute onload with the call of function.

3. For programmers.

window.onload=function(){
    // ... your code here
    BrowserCompatible.check();
}

If you have Javascript functions, which are executed on event onload, then you can add browser verification to the existing function.

It's all! Now, if somebody will visit your site using old browser, he will see the warning message.

Script customization

Warning message can be modified for your site. You can change the following parameters.

1. Minimal browser versions

If needed to forbid access from all the browsers except Firefox 3 and Internet Explorer 8 you need to change following:

<script type="text/javascript">
    BrowserCompatible.compatibleBrowsers = {
        "Firefox": 3,
        "IExplorer": 8
    }
</script>

Now if you visit site using Safari, Opera or earlier version of Firefox or Internet Explorer you will see the warning message.

All browsers which are absent in compatibleBrowsers list or earlier versions of present browsers will incompatible. Which minimal versions are in default settings?

 

2. Browsers black list

If needed to allow access from all the browsers except Internet Explorer 6 and younger you need to change following:

<script type="text/javascript">
    BrowserCompatible.useBlackList = true;
    BrowserCompatible.unCompatibleBrowsers = {
        "IExplorer": 6
    }
</script>

 

3. The list and order of recommended browsers

In warning message user is offered to download one of the browsers. The following array allows you to choose which browsers to show for downloading. The order of the browsers in message depends on its order in array.

<script type="text/javascript">
    BrowserCompatible.offeredBrowsers = [
        "Firefox",
        "Safari",
        "Flock"
    ]
</script>

This is an array of the browsers, in case we want to propose user Gecko-based browsers.By default we propose these browsers.

 

4. The "Close" button

If there is a need to be more loyal to user, you may allow him to close the warning.

<script type="text/javascript">
    BrowserCompatible.allowCancel = true;
</script>

In this case, when opening next page user will see warning again.

5. Chechbox "Don't show next time"

To avoid showing warning message while user goes from page to page you need to turn on the parameter allowToHide. If this parameter turned on, in the botom of the message will be the checkbox "Don't show next time".

<script type="text/javascript">
    BrowserCompatible.allowToHide = true;
</script>

But, I think, it's not recommended to allow two last parameters in cause user may start thinking that your site is working wrong.

6. "Don't show next time" timeout.

When user checkes the option "Don't show next time", information about this will be stored in cookies. The timeout of storing cookies may be set by the following option (in days).

<script type="text/javascript">
    BrowserCompatible.cookiesExpire = 7;
</script>

In such case we will show the warning message again in 7 days after user checked "Don't show next time".

7. Language and texts

You can choose between one of existing languages, or translate all by yourself.

To change the language:

<script type="text/javascript" >
    BrowserCompatible.lang="en";
</script>

The lang parameter can have following values: "uk", "en", "ru", "". If lang= "", the script will detect the language automatically, depending of the visitor's browser language. If browser asks for the warning in non-accessible language (for example, deutch "de") the main language will be english.

If needed, you can change all the text in warning.

<script type="text/javascript" >
BrowserCompatible.langTranslations["en"] : {
    "title": "Incompatible browser",
    "description": "desc...",
    "recomendation": "We recommend...",
    "cancel": "Close the prevention",
    "dontShowAgain": "Don't show this prevention again",
    "Firefox": "Firefox description...",
    "Flock": "Flock description...",
    "IExplorer": "Internet Explorer description...",
    "Safari": "Safari description...",
    "Opera": "Opera description..."
}
</script >

If you have translated warning message to the missing language, we will hapy to add your translation to the standard set of BrowserCompatible. Please mail your translations to ThanksForEmail@goodbyeie6.org.ua

You can change only one part of the warning message. It's obviously that in square brackets it is possible to specify any accessible language.

<script type="text/javascript" >
    BrowserCompatible.langTranslations["en"]. title="New title";
</script >

8. Background images

You can change background images with css selectors in your own css file or by putting the next script:

<script type="text/javascript" >
BrowserCompatible.images = {
    "background": "design/img/ie6_warn.png",
    "cancel": "http://www.imgstok.com/x-button.gif",
}
</script >

Script defaults

The default values is listed below. Author think that this value is optimal. Of course you can change everything yourself.

1. Compatible versions

compatibleBrowsers: {
    "Opera": 9.25,
    "Firefox": 2,
    "IExplorer": 7,
    "Safari": 525.17, //3.1
    "Flock": 1.1
    "Chrome": 1
}

2. Recommended browsers

offeredBrowsers: [
    "Chrome",
    "Firefox",
    "Flock",
    "Safari",
    "IExplorer",
    "Opera"
]

3. "Cancel" buttons

allowCancel: false

4. Checkbox "Don't show next time"

allowToHide: false

5. "Don't show next time" timeout

cookiesExpire: 1

6. Language and localozation

lang: "",
langTranslations: {
    "uk": {
        ...
    },
    "ru": {
        ...
    },
    "en": {
        ...
    }
}