Supporting Legacy Browsers like Microsoft Internet Explorer (IE6 and later versions of IE)

Created by Alison Gianotto, Modified on Fri, 5 Feb, 2021 at 2:53 PM by Alison Gianotto

Usually, this means an old version of IE.


None of the default ‘handlers’ for onGood or onBad are going to work for you, out of the box. You’ll need to set custom handlers for all events.


However, the core of the Javascript snippet should be fully compatible with IE and other legacy browsers that support Javascript.


Here’s an example of some very simple dynamic class changes to support these older browsers:


<html>
    <head>
        <title>Snippet Test</title>
        <meta charset='UTF8'>
        <script src="https://cdn.goodverification.com/verify.js"></script>
       <script src="https://code.jquery.com/jquery-1.12.4.js"></script>
</head>
</style>
    </head>
    <body>
        <style>
            .bad {
                background-color: red
            }
            .good {
                background-color: green
            }
            .bad.good {
                background-color: gray //should not happen!
            }
        </style>
        <p>Okay, let's do a form:<br />
        <form method='POST' action='submit_target.php'>
            Email: <input type='email' size="80" name='email' id='email' /><br />
            <input type='submit' />
        </form></p>
        <script>
            Goodverification('your_form_token', {debug: true,
                onGood: function () {
                    console.warn("Calling good!")
                    $('#email').removeClass("bad").addClass("good");
                    return true;
                },onBad: function () {
                    console.warn("Calling bad!")
                    $('#email').removeClass("good").addClass("bad");
                    return true;
                }
            })
        </script>
    </body>
</html>


Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article