{"id":724,"date":"2026-03-04T00:21:26","date_gmt":"2026-03-04T00:21:26","guid":{"rendered":"https:\/\/cis.aaoifi.com\/login"},"modified":"2026-05-22T14:18:54","modified_gmt":"2026-05-22T14:18:54","slug":"login","status":"publish","type":"page","link":"https:\/\/cis.aaoifi.com\/ru\/login\/","title":{"rendered":"\u0412\u0445\u043e\u0434 \u0432 \u0441\u0438\u0441\u0442\u0435\u043c\u0443"},"content":{"rendered":"\n<div class=\"auth-form-wrapper\">\n    <div class=\"auth-form-container\">\n        <div class=\"auth-header\">\n            <h2>Welcome Back<\/h2>\n            <p>Log in to access your account<\/p>\n        <\/div>\n        \n                \n        <form id=\"login-form\" class=\"auth-form\">\n            <div class=\"form-group\">\n                <label for=\"login_username\">Username or Email<\/label>\n                <input type=\"text\" id=\"login_username\" name=\"username\" class=\"form-control\" required>\n            <\/div>\n            \n            <div class=\"form-group\">\n                <label for=\"login_password\">Password<\/label>\n                <input type=\"password\" id=\"login_password\" name=\"password\" class=\"form-control\" required>\n            <\/div>\n            \n            <div class=\"form-group\">\n                <label class=\"checkbox-label\">\n                    <input type=\"checkbox\" name=\"remember\" value=\"1\">\n                    Remember Me                <\/label>\n            <\/div>\n            \n            <div id=\"login-message\" class=\"auth-message\" style=\"display: none;\"><\/div>\n            \n            <button type=\"submit\" class=\"btn btn-primary btn-block\" id=\"login-btn\">\n                <i class=\"fas fa-sign-in-alt\"><\/i> Log In            <\/button>\n        <\/form>\n        \n        <div class=\"auth-links\">\n            <a href=\"#\" id=\"forgot-password-link\">Forgot Password?<\/a>\n        <\/div>\n        \n        <div class=\"auth-footer\">\n            <p>Don't have an account? <a href=\"https:\/\/cis.aaoifi.com\/ru\/register\/\">Register<\/a><\/p>\n        <\/div>\n    <\/div>\n    \n    <!-- Password Reset Modal -->\n    <div id=\"password-reset-modal\" class=\"auth-modal\" style=\"display: none;\">\n        <div class=\"modal-overlay\"><\/div>\n        <div class=\"modal-content\">\n            <button class=\"modal-close\" id=\"close-reset-modal\">&times;<\/button>\n            <h3>Reset Password<\/h3>\n            <p>Enter your email address and we will send you a password reset link.<\/p>\n            \n            <form id=\"password-reset-form\">\n                <div class=\"form-group\">\n                    <label for=\"reset_email\">Email Address<\/label>\n                    <input type=\"email\" id=\"reset_email\" name=\"email\" class=\"form-control\" required>\n                <\/div>\n                \n                <div id=\"reset-message\" class=\"auth-message\" style=\"display: none;\"><\/div>\n                \n                <button type=\"submit\" class=\"btn btn-primary btn-block\" id=\"reset-btn\">\n                    <i class=\"fas fa-envelope\"><\/i> Send Reset Link                <\/button>\n            <\/form>\n        <\/div>\n    <\/div>\n<\/div>\n\n<script>\njQuery(document).ready(function($) {\n    function authAjaxMessage(xhr, fallback) {\n        if (xhr && xhr.responseJSON && xhr.responseJSON.data && xhr.responseJSON.data.message) {\n            return xhr.responseJSON.data.message;\n        }\n\n        if (xhr && xhr.responseJSON && xhr.responseJSON.message) {\n            return xhr.responseJSON.message;\n        }\n\n        return fallback;\n    }\n\n    function showAuthMessage(selector, type, message) {\n        $(selector)\n            .removeClass('success error')\n            .addClass(type)\n            .empty()\n            .append($('<i>').addClass(type === 'success' ? 'fas fa-check-circle' : 'fas fa-exclamation-circle'))\n            .append(document.createTextNode(' ' + message))\n            .show();\n    }\n\n    \/\/ Login form submission\n    $('#login-form').on('submit', function(e) {\n        e.preventDefault();\n        \n        var formData = {\n            action: 'login_user',\n            nonce: aaoifiAuth.nonce,\n            username: $('#login_username').val(),\n            password: $('#login_password').val(),\n            remember: $('input[name=\"remember\"]').is(':checked') ? 1 : 0\n        };\n        \n        $('#login-btn').prop('disabled', true).html('<i class=\"fas fa-spinner fa-spin\"><\/i> Logging In...');\n        \n        $.ajax({\n            url: aaoifiAuth.ajax_url,\n            type: 'POST',\n            data: formData,\n            success: function(response) {\n                $('#login-btn').prop('disabled', false).html('<i class=\"fas fa-sign-in-alt\"><\/i> Log In');\n                \n                if (response.success) {\n                    $('#login-message')\n                        .removeClass('error')\n                        .addClass('success')\n                        .empty()\n                        .append($('<i>').addClass('fas fa-check-circle'))\n                        .append(document.createTextNode(' ' + response.data.message))\n                        .show();\n                    \n                    setTimeout(function() {\n                        window.location.href = response.data.redirect;\n                    }, 1000);\n                } else {\n                    showAuthMessage('#login-message', 'error', response.data.message);\n                }\n            },\n            error: function(xhr) {\n                $('#login-btn').prop('disabled', false).html('<i class=\"fas fa-sign-in-alt\"><\/i> Log In');\n                showAuthMessage('#login-message', 'error', authAjaxMessage(xhr, 'Login failed. Please refresh the page and try again.'));\n            }\n        });\n    });\n    \n    \/\/ Show password reset modal\n    $('#forgot-password-link').on('click', function(e) {\n        e.preventDefault();\n        $('#password-reset-modal').fadeIn();\n    });\n    \n    \/\/ Close password reset modal\n    $('#close-reset-modal, .modal-overlay').on('click', function() {\n        $('#password-reset-modal').fadeOut();\n    });\n    \n    \/\/ Password reset form submission\n    $('#password-reset-form').on('submit', function(e) {\n        e.preventDefault();\n        \n        var formData = {\n            action: 'reset_password',\n            nonce: aaoifiAuth.nonce,\n            email: $('#reset_email').val()\n        };\n        \n        $('#reset-btn').prop('disabled', true).html('<i class=\"fas fa-spinner fa-spin\"><\/i> Sending...');\n        \n        $.ajax({\n            url: aaoifiAuth.ajax_url,\n            type: 'POST',\n            data: formData,\n            success: function(response) {\n                $('#reset-btn').prop('disabled', false).html('<i class=\"fas fa-envelope\"><\/i> Send Reset Link');\n                \n                if (response.success) {\n                    $('#reset-message')\n                        .removeClass('error')\n                        .addClass('success')\n                        .empty()\n                        .append($('<i>').addClass('fas fa-check-circle'))\n                        .append(document.createTextNode(' ' + response.data.message))\n                        .show();\n                    \n                    setTimeout(function() {\n                        $('#password-reset-modal').fadeOut();\n                        $('#password-reset-form')[0].reset();\n                        $('#reset-message').hide();\n                    }, 3000);\n                } else {\n                    showAuthMessage('#reset-message', 'error', response.data.message);\n                }\n            },\n            error: function(xhr) {\n                $('#reset-btn').prop('disabled', false).html('<i class=\"fas fa-envelope\"><\/i> Send Reset Link');\n                showAuthMessage('#reset-message', 'error', authAjaxMessage(xhr, 'Password reset failed. Please refresh the page and try again.'));\n            }\n        });\n    });\n});\n<\/script>\n\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-724","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/cis.aaoifi.com\/ru\/wp-json\/wp\/v2\/pages\/724","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cis.aaoifi.com\/ru\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/cis.aaoifi.com\/ru\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/cis.aaoifi.com\/ru\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cis.aaoifi.com\/ru\/wp-json\/wp\/v2\/comments?post=724"}],"version-history":[{"count":1,"href":"https:\/\/cis.aaoifi.com\/ru\/wp-json\/wp\/v2\/pages\/724\/revisions"}],"predecessor-version":[{"id":2381,"href":"https:\/\/cis.aaoifi.com\/ru\/wp-json\/wp\/v2\/pages\/724\/revisions\/2381"}],"wp:attachment":[{"href":"https:\/\/cis.aaoifi.com\/ru\/wp-json\/wp\/v2\/media?parent=724"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}