{"id":4139,"date":"2024-01-23T17:30:11","date_gmt":"2024-01-23T17:30:11","guid":{"rendered":"https:\/\/staging.onelamarket.com\/?page_id=4139"},"modified":"2025-02-11T21:56:34","modified_gmt":"2025-02-11T14:56:34","slug":"reset-password","status":"publish","type":"page","link":"https:\/\/household.onelamarket.com\/th\/reset-password\/","title":{"rendered":"Recover Password"},"content":{"rendered":"[et_pb_section fb_built=&#8221;1&#8243; _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; height=&#8221;500px&#8221; hover_enabled=&#8221;0&#8243; global_colors_info=&#8221;{}&#8221; background_enable_image=&#8221;off&#8221; sticky_enabled=&#8221;0&#8243;][et_pb_row _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_text _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;]<h1 style=\"text-align: center;\">\u0e23\u0e35\u0e40\u0e0b\u0e47\u0e15\u0e23\u0e2b\u0e31\u0e2a\u0e1c\u0e48\u0e32\u0e19<\/h1>[\/et_pb_text][\/et_pb_column][\/et_pb_row][et_pb_row column_structure=&#8221;1_3,1_3,1_3&#8243; _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_column type=&#8221;1_3&#8243; _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][\/et_pb_column][et_pb_column type=&#8221;1_3&#8243; _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][et_pb_text _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;]    <div id=\"password-recovery-message\"><\/div>\n    <form id=\"password-recovery-form\" class=\"registration-step-1\" action=\"\">\n        <div class=\"input-wrapper\" style=\"margin-top: 10px\">\n            <svg class=\"icon\" width=\"16\" height=\"16\" viewbox=\"0 0 16 16\" fill=\"none\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\">\n                <path d=\"M2 3.5C1.725 3.5 1.5 3.725 1.5 4V4.69063L6.89062 9.11563C7.5375 9.64688 8.46563 9.64688 9.1125 9.11563L14.5 4.69063V4C14.5 3.725 14.275 3.5 14 3.5H2ZM1.5 6.63125V12C1.5 12.275 1.725 12.5 2 12.5H14C14.275 12.5 14.5 12.275 14.5 12V6.63125L10.0625 10.275C8.8625 11.2594 7.13437 11.2594 5.9375 10.275L1.5 6.63125ZM0 4C0 2.89688 0.896875 2 2 2H14C15.1031 2 16 2.89688 16 4V12C16 13.1031 15.1031 14 14 14H2C0.896875 14 0 13.1031 0 12V4Z\" fill=\"black\" \/>\n            <\/svg>\n            <input class=\"custom-input\" type=\"email\" name=\"user_email\" id=\"user_email\" style=\"background-color: #FFF6D7;\" placeholder=\"\u0e01\u0e23\u0e38\u0e13\u0e32\u0e01\u0e23\u0e2d\u0e01\u0e2d\u0e35\u0e40\u0e21\u0e25\u0e02\u0e2d\u0e07\u0e04\u0e38\u0e13\" required>\n        <\/div>\n        <button type=\"submit\" class=\"submit-button\">\u0e23\u0e35\u0e40\u0e0b\u0e47\u0e15\u0e23\u0e2b\u0e31\u0e2a\u0e1c\u0e48\u0e32\u0e19<\/button>\n\n    <input type=\"hidden\" name=\"trp-form-language\" value=\"th\"\/><\/form>\n\n    <script>\n        jQuery(document).ready(function($) {\n            \/\/ \u0e01\u0e33\u0e2b\u0e19\u0e14 ajaxurl \u0e2a\u0e33\u0e2b\u0e23\u0e31\u0e1a\u0e1c\u0e39\u0e49\u0e43\u0e0a\u0e49\u0e17\u0e35\u0e48\u0e44\u0e21\u0e48\u0e44\u0e14\u0e49 login\n            if (typeof ajaxurl === 'undefined') {\n                var ajaxurl = 'https:\/\/household.onelamarket.com\/wp-admin\/admin-ajax.php';\n            }\n\n            $('#password-recovery-form').on('submit', function(e) {\n                e.preventDefault();\n\n                const email = $('#user_email').val();\n                const messageDiv = $('#password-recovery-message');\n\n                \/\/ Clear previous messages\n                messageDiv.removeClass('success error').empty();\n\n                \/\/ \u0e41\u0e2a\u0e14\u0e07 loading message\n                messageDiv.addClass('info').text('Processing your request...');\n\n                const data = new FormData();\n                data.append('action', 'handle_password_recovery');\n                data.append('email', email);\n                data.append('nonce', 'da7330adc8');\n\n                \/\/ Disable submit button while processing\n                const submitButton = $(this).find('input[type=\"submit\"]');\n                submitButton.prop('disabled', true);\n\n                fetch(ajaxurl, {\n                        method: 'POST',\n                        credentials: 'same-origin',\n                        body: data\n                    })\n                    .then(response => response.json())\n                    .then(data => {\n                        if (data.success) {\n                            messageDiv.removeClass('info').addClass('success').text(data.data);\n                            $('#user_email').val(''); \/\/ Clear the form\n                        } else {\n                            messageDiv.removeClass('info').addClass('error').text(data.data);\n                        }\n                    })\n                    .catch(error => {\n                        messageDiv.removeClass('info').addClass('error').text('An error occurred. Please try again.');\n                        console.error('Error:', error);\n                    })\n                    .finally(() => {\n                        \/\/ Re-enable submit button\n                        submitButton.prop('disabled', false);\n                    });\n            });\n        });\n    <\/script>\n\n    <style>\n        #password-recovery-message {\n            margin: 10px 0;\n            padding: 10px;\n            border-radius: 4px;\n        }\n\n        #password-recovery-message.success {\n            background-color: #d4edda;\n            color: #155724;\n            border: 1px solid #c3e6cb;\n        }\n\n        #password-recovery-message.error {\n            background-color: #f8d7da;\n            color: #721c24;\n            border: 1px solid #f5c6cb;\n        }\n\n        #password-recovery-message.info {\n            background-color: #e2e3e5;\n            color: #383d41;\n            border: 1px solid #d6d8db;\n        }\n\n        .submit-button:disabled {\n            opacity: 0.7;\n            cursor: not-allowed;\n        }\n    <\/style>\n[\/et_pb_text][\/et_pb_column][et_pb_column type=&#8221;1_3&#8243; _builder_version=&#8221;4.23.1&#8243; _module_preset=&#8221;default&#8221; global_colors_info=&#8221;{}&#8221;][\/et_pb_column][\/et_pb_row][\/et_pb_section]","protected":false},"excerpt":{"rendered":"<p>\u0e23\u0e35\u0e40\u0e0b\u0e47\u0e15\u0e23\u0e2b\u0e31\u0e2a\u0e1c\u0e48\u0e32\u0e19    <div id=\"password-recovery-message\"><\/div>\n    <form id=\"password-recovery-form\" class=\"registration-step-1\" action=\"\">\n        <div class=\"input-wrapper\" style=\"margin-top: 10px\">\n            <svg class=\"icon\" width=\"16\" height=\"16\" viewbox=\"0 0 16 16\" fill=\"none\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\">\n                <path d=\"M2 3.5C1.725 3.5 1.5 3.725 1.5 4V4.69063L6.89062 9.11563C7.5375 9.64688 8.46563 9.64688 9.1125 9.11563L14.5 4.69063V4C14.5 3.725 14.275 3.5 14 3.5H2ZM1.5 6.63125V12C1.5 12.275 1.725 12.5 2 12.5H14C14.275 12.5 14.5 12.275 14.5 12V6.63125L10.0625 10.275C8.8625 11.2594 7.13437 11.2594 5.9375 10.275L1.5 6.63125ZM0 4C0 2.89688 0.896875 2 2 2H14C15.1031 2 16 2.89688 16 4V12C16 13.1031 15.1031 14 14 14H2C0.896875 14 0 13.1031 0 12V4Z\" fill=\"black\" \/>\n            <\/svg>\n            <input class=\"custom-input\" type=\"email\" name=\"user_email\" id=\"user_email\" style=\"background-color: #FFF6D7;\" placeholder=\"\u0e01\u0e23\u0e38\u0e13\u0e32\u0e01\u0e23\u0e2d\u0e01\u0e2d\u0e35\u0e40\u0e21\u0e25\u0e02\u0e2d\u0e07\u0e04\u0e38\u0e13\" required>\n        <\/div>\n        <button type=\"submit\" class=\"submit-button\">\u0e23\u0e35\u0e40\u0e0b\u0e47\u0e15\u0e23\u0e2b\u0e31\u0e2a\u0e1c\u0e48\u0e32\u0e19<\/button>\n\n    <input type=\"hidden\" name=\"trp-form-language\" value=\"th\"\/><\/form>\n\n    <script>\n        jQuery(document).ready(function($) {\n            \/\/ \u0e01\u0e33\u0e2b\u0e19\u0e14 ajaxurl \u0e2a\u0e33\u0e2b\u0e23\u0e31\u0e1a\u0e1c\u0e39\u0e49\u0e43\u0e0a\u0e49\u0e17\u0e35\u0e48\u0e44\u0e21\u0e48\u0e44\u0e14\u0e49 login\n            if (typeof ajaxurl === 'undefined') {\n                var ajaxurl = 'https:\/\/household.onelamarket.com\/wp-admin\/admin-ajax.php';\n            }\n\n            $('#password-recovery-form').on('submit', function(e) {\n                e.preventDefault();\n\n                const email = $('#user_email').val();\n                const messageDiv = $('#password-recovery-message');\n\n                \/\/ Clear previous messages\n                messageDiv.removeClass('success error').empty();\n\n                \/\/ \u0e41\u0e2a\u0e14\u0e07 loading message\n                messageDiv.addClass('info').text('Processing your request...');\n\n                const data = new FormData();\n                data.append('action', 'handle_password_recovery');\n                data.append('email', email);\n                data.append('nonce', 'da7330adc8');\n\n                \/\/ Disable submit button while processing\n                const submitButton = $(this).find('input[type=\"submit\"]');\n                submitButton.prop('disabled', true);\n\n                fetch(ajaxurl, {\n                        method: 'POST',\n                        credentials: 'same-origin',\n                        body: data\n                    })\n                    .then(response => response.json())\n                    .then(data => {\n                        if (data.success) {\n                            messageDiv.removeClass('info').addClass('success').text(data.data);\n                            $('#user_email').val(''); \/\/ Clear the form\n                        } else {\n                            messageDiv.removeClass('info').addClass('error').text(data.data);\n                        }\n                    })\n                    .catch(error => {\n                        messageDiv.removeClass('info').addClass('error').text('An error occurred. Please try again.');\n                        console.error('Error:', error);\n                    })\n                    .finally(() => {\n                        \/\/ Re-enable submit button\n                        submitButton.prop('disabled', false);\n                    });\n            });\n        });\n    <\/script>\n\n    <style>\n        #password-recovery-message {\n            margin: 10px 0;\n            padding: 10px;\n            border-radius: 4px;\n        }\n\n        #password-recovery-message.success {\n            background-color: #d4edda;\n            color: #155724;\n            border: 1px solid #c3e6cb;\n        }\n\n        #password-recovery-message.error {\n            background-color: #f8d7da;\n            color: #721c24;\n            border: 1px solid #f5c6cb;\n        }\n\n        #password-recovery-message.info {\n            background-color: #e2e3e5;\n            color: #383d41;\n            border: 1px solid #d6d8db;\n        }\n\n        .submit-button:disabled {\n            opacity: 0.7;\n            cursor: not-allowed;\n        }\n    <\/style>\n<\/p>","protected":false},"author":7886,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_et_pb_use_builder":"on","_et_pb_old_content":"","_et_gb_content_width":"","footnotes":""},"class_list":["post-4139","page","type-page","status-publish","hentry"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/household.onelamarket.com\/th\/wp-json\/wp\/v2\/pages\/4139","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/household.onelamarket.com\/th\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/household.onelamarket.com\/th\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/household.onelamarket.com\/th\/wp-json\/wp\/v2\/users\/7886"}],"replies":[{"embeddable":true,"href":"https:\/\/household.onelamarket.com\/th\/wp-json\/wp\/v2\/comments?post=4139"}],"version-history":[{"count":0,"href":"https:\/\/household.onelamarket.com\/th\/wp-json\/wp\/v2\/pages\/4139\/revisions"}],"wp:attachment":[{"href":"https:\/\/household.onelamarket.com\/th\/wp-json\/wp\/v2\/media?parent=4139"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}