{"id":504,"date":"2026-05-06T18:07:04","date_gmt":"2026-05-06T18:07:04","guid":{"rendered":"https:\/\/my247coach.online\/index.php\/cancelar-suscripcion\/"},"modified":"2026-05-06T18:07:04","modified_gmt":"2026-05-06T18:07:04","slug":"cancelar-suscripcion","status":"publish","type":"page","link":"https:\/\/my247coach.online\/index.php\/cancelar-suscripcion\/","title":{"rendered":"Cancelar suscripci\u00f3n"},"content":{"rendered":"        <div class=\"my247-newsletter-unsubscribe\"\n             data-lang=\"es\"\n             data-ajax-url=\"https:\/\/my247coach.online\/wp-admin\/admin-ajax.php\"\n             data-nonce=\"c0e3009359\"\n             data-token=\"\">\n\n            <p class=\"my247-newsletter-notice error\">Este enlace de baja es inv\u00e1lido o ha caducado.<\/p>        <\/div>\n\n                <style>\n        .my247-newsletter-strip { margin: 32px 0 20px; font-family: -apple-system, BlinkMacSystemFont,\n            'Segoe UI', Roboto, sans-serif; }\n        .my247-newsletter-strip-inner { background: #f8fafc; border: 1px solid #e2e8f0;\n            border-radius: 8px; padding: 18px 22px; color: #1e293b; }\n        .my247-newsletter-strip-heading { margin: 0 0 6px; font-size: 15px; color: #334155;\n            font-weight: 600; }\n        .my247-newsletter-strip-body { margin: 0 0 12px; font-size: 14px; color: #475569;\n            line-height: 1.5; }\n        .my247-newsletter-row { display: flex; gap: 10px; margin-bottom: 10px; }\n        .my247-newsletter-email { flex: 1; padding: 9px 12px; border: 1px solid #cbd5e1;\n            border-radius: 6px; font-size: 14px; font-family: inherit; box-sizing: border-box; }\n        .my247-newsletter-submit { background: #2563eb; color: #fff; border: 0;\n            padding: 9px 18px; border-radius: 6px; font-size: 14px; font-weight: 600;\n            cursor: pointer; white-space: nowrap; }\n        .my247-newsletter-submit:hover { background: #1d4ed8; }\n        .my247-newsletter-submit:disabled { opacity: 0.6; cursor: wait; }\n        .my247-newsletter-consent { display: flex; align-items: flex-start; gap: 8px;\n            font-size: 12px; color: #64748b; line-height: 1.4; }\n        .my247-newsletter-consent input { margin-top: 3px; flex-shrink: 0; }\n        .my247-newsletter-msg { margin-top: 10px; padding: 9px 12px; border-radius: 6px;\n            font-size: 13px; }\n        .my247-newsletter-msg.success { background: #dcfce7; border: 1px solid #16a34a; color: #14532d; }\n        .my247-newsletter-msg.error   { background: #fee2e2; border: 1px solid #dc2626; color: #7f1d1d; }\n        .my247-newsletter-unsubscribe { max-width: 640px; margin: 40px auto; padding: 24px;\n            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;\n            color: #1e293b; }\n        .my247-newsletter-unsubscribe h2 { font-size: 22px; margin: 0 0 12px; }\n        .my247-newsletter-unsub-btn { background: #dc2626; color: #fff; border: 0;\n            padding: 12px 22px; border-radius: 6px; font-size: 15px; font-weight: 600;\n            cursor: pointer; margin-top: 16px; }\n        .my247-newsletter-unsub-btn:hover { background: #b91c1c; }\n        .my247-newsletter-unsub-btn:disabled { opacity: 0.6; cursor: wait; }\n        .my247-newsletter-unsub-result { margin-top: 16px; padding: 10px 14px;\n            border-radius: 6px; }\n        .my247-newsletter-unsub-result.success { background: #dcfce7; border: 1px solid #16a34a; color: #14532d; }\n        .my247-newsletter-unsub-result.error   { background: #fee2e2; border: 1px solid #dc2626; color: #7f1d1d; }\n        .my247-newsletter-notice { padding: 14px 18px; border-radius: 6px; background: #f1f5f9;\n            border: 1px solid #cbd5e1; color: #334155; font-size: 15px; }\n        .my247-newsletter-notice.error { background: #fee2e2; border-color: #dc2626; color: #7f1d1d; }\n        @media (max-width: 480px) {\n            .my247-newsletter-row { flex-direction: column; }\n        }\n        <\/style>\n                        <script>\n        (function() {\n            var roots = document.querySelectorAll('.my247-newsletter-unsubscribe');\n            roots.forEach(function(root) {\n                if (root.dataset.bound === '1') return;\n                root.dataset.bound = '1';\n\n                var btn    = root.querySelector('.my247-newsletter-unsub-btn');\n                var result = root.querySelector('.my247-newsletter-unsub-result');\n                var ajaxUrl = root.getAttribute('data-ajax-url');\n                var nonce   = root.getAttribute('data-nonce');\n                var lang    = root.getAttribute('data-lang') || 'nl';\n                var token   = root.getAttribute('data-token');\n                if (!btn) return;\n\n                function showResult(text, kind) {\n                    if (!result) return;\n                    result.textContent = text || '';\n                    result.className = 'my247-newsletter-unsub-result ' + (kind || 'success');\n                    result.style.display = 'block';\n                }\n\n                btn.addEventListener('click', function(e) {\n                    e.preventDefault();\n                    btn.disabled = true;\n\n                    fetch(ajaxUrl, {\n                        method: 'POST',\n                        headers: {'Content-Type': 'application\/x-www-form-urlencoded'},\n                        body: new URLSearchParams({\n                            action: 'my247coach_newsletter_unsubscribe',\n                            nonce: nonce,\n                            lang: lang,\n                            token: token || ''\n                        }),\n                        credentials: 'same-origin'\n                    })\n                        .then(function(r) { return r.json(); })\n                        .then(function(data) {\n                            if (data && data.success) {\n                                showResult((data.data && data.data.message) || '\u2713', 'success');\n                                btn.style.display = 'none';\n                            } else {\n                                showResult((data && data.data && data.data.message) || 'Error', 'error');\n                                btn.disabled = false;\n                            }\n                        })\n                        .catch(function(err) {\n                            showResult(String(err), 'error');\n                            btn.disabled = false;\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-504","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/my247coach.online\/index.php\/wp-json\/wp\/v2\/pages\/504","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/my247coach.online\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/my247coach.online\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/my247coach.online\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/my247coach.online\/index.php\/wp-json\/wp\/v2\/comments?post=504"}],"version-history":[{"count":0,"href":"https:\/\/my247coach.online\/index.php\/wp-json\/wp\/v2\/pages\/504\/revisions"}],"wp:attachment":[{"href":"https:\/\/my247coach.online\/index.php\/wp-json\/wp\/v2\/media?parent=504"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}