{"id":365,"date":"2025-07-23T20:48:03","date_gmt":"2025-07-23T20:48:03","guid":{"rendered":"https:\/\/tree-of-mylife.com\/?page_id=365"},"modified":"2025-12-09T04:10:51","modified_gmt":"2025-12-09T04:10:51","slug":"education","status":"publish","type":"page","link":"https:\/\/tree-of-mylife.com\/es\/education\/","title":{"rendered":"education"},"content":{"rendered":"\n<div style=\"padding:60px 20px; font-family:Arial, sans-serif;\">\n  <!-- Tarjeta con \u00e1rbol de fondo -->\n  <div style=\"\n    max-width:800px; margin:auto; padding:30px; border-radius:15px;\n    box-shadow:0 12px 30px rgba(0,0,0,.25); color:#001f54;\n    background: url('https:\/\/tree-of-mylife.com\/wp-content\/uploads\/2025\/07\/ChatGPT-Image-Jul-21-2025-04_27_41-PM.png') center\/cover no-repeat;\n    background-color: rgba(255,255,255,0.2);\n  \">\n    <h2 style=\"text-align:center; font-size:34px; color:#001f54; margin:0 0 20px; text-shadow:1px 1px 2px #fff;\">\n      Education \/ Educaci\u00f3n\n    <\/h2>\n\n    <!-- Selector de idioma -->\n    <div style=\"text-align:right; margin-bottom:15px;\">\n      <label for=\"lang\" style=\"font-weight:bold;\">Language \/ Idioma:<\/label>\n      <select id=\"lang\" style=\"padding:5px; border-radius:6px;\">\n        <option value=\"en\">English<\/option>\n        <option value=\"es\">Espa\u00f1ol<\/option>\n      <\/select>\n    <\/div>\n\n    <form id=\"eduForm\">\n      <div id=\"edu-container\">\n        <!-- Bloque de educaci\u00f3n -->\n        <div class=\"edu-block\" style=\"margin-bottom:26px; border-bottom:1px solid rgba(0,0,0,.15); padding-bottom:18px; background-color:rgba(255,255,255,0.5); border-radius:8px; padding:15px;\">\n          <label>School \/ Institution<\/label>\n          <input type=\"text\" name=\"school[]\" style=\"width:100%; padding:10px; margin:6px 0 12px; border-radius:8px; border:1px solid #ccc;\">\n\n          <label>Degree \/ Certification<\/label>\n          <input type=\"text\" name=\"degree[]\" style=\"width:100%; padding:10px; margin:6px 0 12px; border-radius:8px; border:1px solid #ccc;\">\n\n          <label>Field of Study<\/label>\n          <input type=\"text\" name=\"field[]\" style=\"width:100%; padding:10px; margin:6px 0 12px; border-radius:8px; border:1px solid #ccc;\">\n\n          <div style=\"display:flex; gap:12px; flex-wrap:wrap;\">\n            <div style=\"flex:1; min-width:180px;\">\n              <label>Start Date<\/label>\n              <input type=\"date\" name=\"start_date[]\" style=\"width:100%; padding:10px; margin:6px 0 12px; border-radius:8px; border:1px solid #ccc;\">\n            <\/div>\n            <div style=\"flex:1; min-width:180px;\">\n              <label>End Date<\/label>\n              <input type=\"date\" name=\"end_date[]\" class=\"end-date\" style=\"width:100%; padding:10px; margin:6px 0 12px; border-radius:8px; border:1px solid #ccc;\">\n            <\/div>\n          <\/div>\n\n          <label style=\"display:inline-flex; align-items:center; gap:8px; margin:0 0 12px;\">\n            <input type=\"checkbox\" class=\"current\" style=\"transform:scale(1.1);\"> Current \/ Ongoing\n          <\/label>\n\n          <label>Description<\/label>\n          <textarea name=\"description[]\" rows=\"4\" style=\"width:100%; padding:10px; margin:6px 0 12px; border-radius:8px; border:1px solid #ccc;\"><\/textarea>\n\n          <!-- Bot\u00f3n eliminar (solo en clones) -->\n          <button type=\"button\" class=\"remove-block\" style=\"display:none; background:#c0392b; color:#fff; border:none; border-radius:8px; padding:8px 12px; cursor:pointer;\">\n            Remove\n          <\/button>\n        <\/div>\n      <\/div>\n\n      <div style=\"display:flex; gap:10px; flex-wrap:wrap; margin-bottom:20px;\">\n        <button type=\"button\" onclick=\"addEdu()\" style=\"background:#001f54; color:#fff; padding:10px 16px; border:none; border-radius:8px; cursor:pointer;\">\n          + Add Another Education\n        <\/button>\n        <button type=\"submit\" style=\"background:#2ecc71; color:#fff; padding:12px 18px; border:none; border-radius:8px; cursor:pointer;\">\n          Submit\n        <\/button>\n      <\/div>\n    <\/form>\n\n    <!-- Botones de compartir -->\n    <div style=\"text-align:center; margin-top:20px;\">\n      <button onclick=\"downloadJSON()\" style=\"background:#3498db; color:#fff; padding:10px 16px; border:none; border-radius:8px; margin:5px; cursor:pointer;\">Download JSON<\/button>\n      <button onclick=\"window.print()\" style=\"background:#9b59b6; color:#fff; padding:10px 16px; border:none; border-radius:8px; margin:5px; cursor:pointer;\">Print<\/button>\n      <button onclick=\"shareForm()\" style=\"background:#e67e22; color:#fff; padding:10px 16px; border:none; border-radius:8px; margin:5px; cursor:pointer;\">Share<\/button>\n    <\/div>\n  <\/div>\n<\/div>\n\n<script>\n  function wireUp(block){\n    const current = block.querySelector('.current');\n    const end = block.querySelector('.end-date');\n    const removeBtn = block.querySelector('.remove-block');\n\n    if(current && end){\n      current.addEventListener('change', () => {\n        if(current.checked){\n          end.value = '';\n          end.disabled = true;\n          end.style.opacity = .6;\n        } else {\n          end.disabled = false;\n          end.style.opacity = 1;\n        }\n      });\n    }\n    if(removeBtn && block.dataset.cloned === 'true'){\n      removeBtn.style.display = 'inline-block';\n      removeBtn.addEventListener('click', () => block.remove());\n    }\n  }\n\n  function addEdu(){\n    const container = document.getElementById('edu-container');\n    const first = container.querySelector('.edu-block');\n    const clone = first.cloneNode(true);\n\n    clone.querySelectorAll('input, textarea').forEach(el=>{\n      if(el.type === 'checkbox'){ el.checked = false; return; }\n      el.value = '';\n      if(el.classList.contains('end-date')){ el.disabled = false; el.style.opacity = 1; }\n    });\n\n    clone.dataset.cloned = 'true';\n    wireUp(clone);\n    container.appendChild(clone);\n  }\n\n  function downloadJSON(){\n    const data = new FormData(document.getElementById('eduForm'));\n    let obj = {};\n    data.forEach((v,k)=>{\n      if(!obj[k]) obj[k] = [];\n      obj[k].push(v);\n    });\n    const blob = new Blob([JSON.stringify(obj,null,2)], {type:'application\/json'});\n    const url = URL.createObjectURL(blob);\n    const a = document.createElement('a');\n    a.href = url;\n    a.download = \"education.json\";\n    a.click();\n    URL.revokeObjectURL(url);\n  }\n\n  function shareForm(){\n    if(navigator.share){\n      navigator.share({\n        title: \"Education Form\",\n        text: \"Fill out this Education Form:\",\n        url: window.location.href\n      });\n    } else {\n      alert(\"Sharing not supported on this browser.\");\n    }\n  }\n\n  document.addEventListener('DOMContentLoaded', ()=>{\n    document.querySelectorAll('.edu-block').forEach(wireUp);\n  });\n<\/script>\n\n\n\n\n<p class=\"wp-block-paragraph\"><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Education \/ Educaci\u00f3n Language \/ Idioma: EnglishEspa\u00f1ol School \/ Institution Degree \/ Certification Field of Study Start Date End Date Current \/ Ongoing Description Remove + Add Another Education Submit Download JSON Print Share<\/p>","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_coblocks_attr":"","_coblocks_dimensions":"","_coblocks_responsive_height":"","_coblocks_accordion_ie_support":"","pmpro_default_level":"","site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"set","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"class_list":["post-365","page","type-page","status-publish","hentry","pmpro-has-access"],"_links":{"self":[{"href":"https:\/\/tree-of-mylife.com\/es\/wp-json\/wp\/v2\/pages\/365","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tree-of-mylife.com\/es\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/tree-of-mylife.com\/es\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/tree-of-mylife.com\/es\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/tree-of-mylife.com\/es\/wp-json\/wp\/v2\/comments?post=365"}],"version-history":[{"count":14,"href":"https:\/\/tree-of-mylife.com\/es\/wp-json\/wp\/v2\/pages\/365\/revisions"}],"predecessor-version":[{"id":701,"href":"https:\/\/tree-of-mylife.com\/es\/wp-json\/wp\/v2\/pages\/365\/revisions\/701"}],"wp:attachment":[{"href":"https:\/\/tree-of-mylife.com\/es\/wp-json\/wp\/v2\/media?parent=365"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}