{"id":250,"date":"2017-05-07T16:14:27","date_gmt":"2017-05-07T16:14:27","guid":{"rendered":"http:\/\/fieldofdreamsfarmtn.com\/?page_id=250"},"modified":"2017-05-07T17:22:22","modified_gmt":"2017-05-07T17:22:22","slug":"update-me","status":"publish","type":"page","link":"https:\/\/fieldofdreamsfarmtn.com\/?page_id=250","title":{"rendered":"Update me"},"content":{"rendered":"\n            <div id=\"mailerlite-form_3\" data-temp-id=\"69f2bc46aa4b2\">\n                <div class=\"mailerlite-form\">\n                    <form action=\"\" method=\"post\" novalidate>\n                                                    <div class=\"mailerlite-form-title\"><h3>Keep up with us??<\/h3><\/div>\n                                                <div class=\"mailerlite-form-description\"><p><span style=\"color: #000000\">Sign up and we'll keep you updated on product offerings, delivery schedules and reminders.<\/span><\/p>\n<\/div>\n                        <div class=\"mailerlite-form-inputs\">\n                                                                                            <div class=\"mailerlite-form-field\">\n                                    <label for=\"mailerlite-3-field-email\">Email<\/label>\n                                    <input id=\"mailerlite-3-field-email\"\n                                           type=\"email\" required=\"required\"                                            name=\"form_fields[email]\"\n                                           placeholder=\"Email\"\/>\n                                <\/div>\n                                                                                            <div class=\"mailerlite-form-field\">\n                                    <label for=\"mailerlite-3-field-name\">First Name<\/label>\n                                    <input id=\"mailerlite-3-field-name\"\n                                           type=\"text\"                                            name=\"form_fields[name]\"\n                                           placeholder=\"First Name\"\/>\n                                <\/div>\n                                                                                            <div class=\"mailerlite-form-field\">\n                                    <label for=\"mailerlite-3-field-last_name\">Last name<\/label>\n                                    <input id=\"mailerlite-3-field-last_name\"\n                                           type=\"text\"                                            name=\"form_fields[last_name]\"\n                                           placeholder=\"Last name\"\/>\n                                <\/div>\n                                                        <div class=\"mailerlite-form-loader\">hold on...hold on....<\/div>\n                            <div class=\"mailerlite-subscribe-button-container\">\n                                <button class=\"mailerlite-subscribe-submit\" type=\"submit\">\n                                    Yes! I want to follow you                                <\/button>\n                            <\/div>\n                            <input type=\"hidden\" name=\"form_id\" value=\"3\"\/>\n                            <input type=\"hidden\" name=\"action\" value=\"mailerlite_subscribe_form\"\/>\n                            <input type=\"hidden\" name=\"ml_nonce\" value=\"cd1b7cf558\"\/>\n                        <\/div>\n                        <div class=\"mailerlite-form-response\">\n                                                            <h4><p><span style=\"color: #000000\">We are so glad to have you!! Thanks for being a part of our farm<\/span><\/p>\n<\/h4>\n                                                    <\/div>\n                    <\/form>\n                <\/div>\n            <\/div>\n        <script type=\"text\/javascript\" src='https:\/\/fieldofdreamsfarmtn.com\/wp-content\/plugins\/official-mailerlite-sign-up-forms\/assets\/js\/localization\/validation-messages.js'><\/script>\n         <script type=\"text\/javascript\"> var selectedLanguage = \"\"; var validationMessages = messages[\"en\"]; if(selectedLanguage) { validationMessages = messages[selectedLanguage]; } window.addEventListener(\"load\", function () { var form_container = document.querySelector(`#mailerlite-form_3[data-temp-id=\"69f2bc46aa4b2\"] form`); let submitButton = form_container.querySelector('.mailerlite-subscribe-submit'); submitButton.disabled = true; fetch('https:\/\/fieldofdreamsfarmtn.com\/wp-admin\/admin-ajax.php', { method: 'POST', headers:{ 'Content-Type': 'application\/x-www-form-urlencoded', }, body: new URLSearchParams({ \"action\" : \"ml_create_nonce\", \"ml_nonce\" : form_container.querySelector(\"input[name='ml_nonce']\").value }) }) .then((response) => response.json()) .then((json) => { if(json.success) { form_container.querySelector(\"input[name='ml_nonce']\").value = json.data.ml_nonce; submitButton.disabled = false; } }) .catch((error) => { console.error('Error:', error); }); form_container.addEventListener('submit', (e) => { e.preventDefault(); let data = new URLSearchParams(new FormData(form_container)).toString(); let validationError = false; document.querySelectorAll('.mailerlite-form-error').forEach(el => el.remove()); Array.from(form_container.elements).forEach((input) => { if(input.type !== 'hidden') { if(input.required) { if(input.value == '') { validationError = true; let error = document.createElement(\"span\"); error.className = 'mailerlite-form-error'; error.textContent = validationMessages.required; input.after(error); return false; } } if((input.type == \"email\") && (!validateEmail(input.value))) { validationError = true; let error = document.createElement(\"span\"); error.className = 'mailerlite-form-error'; error.textContent = validationMessages.email; input.after(error); return false; } } }); if(validationError) { return false; } fade.out(form_container.querySelector('.mailerlite-subscribe-button-container'), () => { fade.in(form_container.querySelector('.mailerlite-form-loader')); }); fetch('https:\/\/fieldofdreamsfarmtn.com\/wp-admin\/admin-ajax.php', { method: 'POST', headers:{ 'Content-Type': 'application\/x-www-form-urlencoded', }, body: data }) .then((response) => { fade.out(form_container.querySelector('.mailerlite-form-inputs'), () => { fade.in(form_container.querySelector('.mailerlite-form-response')); }); }) .catch((error) => { console.error('Error:', error); }); }); }, false); var fade = { out: function(el, fn = false) { var fadeOutEffect = setInterval(function () { if (!el.style.opacity) { el.style.opacity = 1; } if (el.style.opacity > 0) { el.style.opacity -= 0.1; } else { el.style.display = 'none'; clearInterval(fadeOutEffect); } }, 50); if( typeof (fn) == 'function') { fn(); } }, in: function(el) { var fadeInEffect = setInterval(function () { if (!el.style.opacity) { el.style.opacity = 0; } if (el.style.opacity < 1) { el.style.opacity = Number(el.style.opacity) + 0.1; } else { el.style.display = 'block'; clearInterval(fadeInEffect); } }, 50); } }; function validateEmail(email){ if(email.match( \/^(([^<>()[\\]\\\\.,;:\\s@\\\"]+(\\.[^<>()[\\]\\\\.,;:\\s@\\\"]+)*)|(\\\".+\\\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$\/ )) { return true; } return false; } <\/script> \n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp;<\/p>\n","protected":false},"author":1,"featured_media":245,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"jetpack_post_was_ever_published":false,"footnotes":""},"class_list":["post-250","page","type-page","status-publish","has-post-thumbnail","hentry"],"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/P8Gxfv-42","jetpack-related-posts":[{"id":72,"url":"https:\/\/fieldofdreamsfarmtn.com\/?page_id=72","url_meta":{"origin":250,"position":0},"title":"Beef","author":"admin","date":"February 24, 2017","format":false,"excerpt":"\u00a0Where's the BEEF?? \u00a0Right here and it's 100% grass fed \/ finished and free of antibiotics and vaccinations. \u00a0We raise mostly Black Angus with some Angus \/ Seminole mix and Charolais. How our beef is sold? \u00a0We typically sell 1\/4, 1\/2 or Whole beeves. \u00a0We charge $3.00 \/ lb live\u2026","rel":"","context":"Similar post","block_context":{"text":"Similar post","link":""},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/fieldofdreamsfarmtn.com\/wp-content\/uploads\/2017\/04\/18058200_1409413892454853_2782401827754551245_n.jpg?resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/fieldofdreamsfarmtn.com\/wp-content\/uploads\/2017\/04\/18058200_1409413892454853_2782401827754551245_n.jpg?resize=350%2C200 1x, https:\/\/i0.wp.com\/fieldofdreamsfarmtn.com\/wp-content\/uploads\/2017\/04\/18058200_1409413892454853_2782401827754551245_n.jpg?resize=525%2C300 1.5x, https:\/\/i0.wp.com\/fieldofdreamsfarmtn.com\/wp-content\/uploads\/2017\/04\/18058200_1409413892454853_2782401827754551245_n.jpg?resize=700%2C400 2x"},"classes":[]},{"id":153,"url":"https:\/\/fieldofdreamsfarmtn.com\/?page_id=153","url_meta":{"origin":250,"position":1},"title":"Delivery Schedule &#038; Farm Hours","author":"admin","date":"April 22, 2017","format":false,"excerpt":"Product deliveries are every other week at these locations: Every 2 weeks on Tuesdays: (dates in 2026:\u00a0 Jan 6th, Jan 20th, Feb 3rd and 17th, March 3rd, and 17th, March 31st, April 14th and 28th, May 12th and 26th, June 9th and 23rd, July 7th and 21st, Aug 4th and\u2026","rel":"","context":"Similar post","block_context":{"text":"Similar post","link":""},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"_links":{"self":[{"href":"https:\/\/fieldofdreamsfarmtn.com\/index.php?rest_route=\/wp\/v2\/pages\/250","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fieldofdreamsfarmtn.com\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/fieldofdreamsfarmtn.com\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/fieldofdreamsfarmtn.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fieldofdreamsfarmtn.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=250"}],"version-history":[{"count":9,"href":"https:\/\/fieldofdreamsfarmtn.com\/index.php?rest_route=\/wp\/v2\/pages\/250\/revisions"}],"predecessor-version":[{"id":274,"href":"https:\/\/fieldofdreamsfarmtn.com\/index.php?rest_route=\/wp\/v2\/pages\/250\/revisions\/274"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/fieldofdreamsfarmtn.com\/index.php?rest_route=\/wp\/v2\/media\/245"}],"wp:attachment":[{"href":"https:\/\/fieldofdreamsfarmtn.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=250"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}