put[name=username]').select().focus();
        } else if (el.is('.redirect-form')) {
            var loc = encodeURIComponent(document.location.href);
            var url = el.attr('action').replace('{{url}}', encodeURIComponent(loc)); // double escape
            document.location.href = url.replace('{url}', loc); // single escape
        }
    }

    $('.choose-mechanism').click(function() {
        var el = $('#'+ this.id.substring(7)); // choose-mechanism-1 -> mechanism-1
        el.css('display', 'bloc