{"id":722,"date":"2024-11-05T02:32:30","date_gmt":"2024-11-05T02:32:30","guid":{"rendered":"http:\/\/localhost\/?p=722"},"modified":"2024-12-22T06:11:18","modified_gmt":"2024-12-22T06:11:18","slug":"check-essay-with-sample-full-demo","status":"publish","type":"post","link":"https:\/\/studaca.online\/check-essay-with-sample-full-demo\/","title":{"rendered":"Check Essay With Sample Full Demo"},"content":{"rendered":"\n<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n    <meta charset=\"UTF-8\">\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n    <title>Text Analysis<\/title>\n<\/head>\n<body>\n    <h1>Text Analysis Form<\/h1>\n    <form id=\"textAnalysisForm\">\n\n<label for=\"text\">Question:<\/label>\n        <textarea id=\"text\" name=\"text\" rows=\"4\" required><\/textarea><br><br>\n\n        <label for=\"sample\">Sample Sentence:<\/label>\n        <textarea type=\"text\" id=\"sample\" name=\"sample\" required><\/textarea> <br><br>\n\n        <label for=\"useressay\">User Essay:<\/label>\n        <textarea type=\"text\" id=\"useressay\" name=\"useressay\" required><\/textarea><br><br>\n\n        \n\n        <button type=\"submit\">Analyze<\/button>\n    <\/form>\n\n    <h2>Results<\/h2>\n    <pre id=\"result\"><\/pre>\n\n    <script>\n        document.getElementById('textAnalysisForm').addEventListener('submit', function(event) {\n            event.preventDefault(); \/\/ Prevent form submission\n\n            const sample = document.getElementById('sample').value;\n            const useressay = document.getElementById('useressay').value;\n            const text = document.getElementById('text').value;\n\n            \/\/ Make API request\n            fetch('http:\/\/localhost\/api\/v1\/analyze-text', {\n                method: 'POST',\n                headers: {\n                    'Content-Type': 'application\/json',\n                },\n                body: JSON.stringify({ sample, useressay, text })\n            })\n            .then(response => response.json())\n            .then(data => {\n                document.getElementById('result').textContent = JSON.stringify(data, null, 2);\n            })\n            .catch(error => {\n                console.error('Error:', error);\n            });\n        });\n    <\/script>\n<\/body>\n<\/html>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Text Analysis Text Analysis Form Question: Sample Sentence: User Essay: Analyze Results<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-722","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/studaca.online\/api\/wp\/v2\/posts\/722","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/studaca.online\/api\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/studaca.online\/api\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/studaca.online\/api\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/studaca.online\/api\/wp\/v2\/comments?post=722"}],"version-history":[{"count":18,"href":"https:\/\/studaca.online\/api\/wp\/v2\/posts\/722\/revisions"}],"predecessor-version":[{"id":1085,"href":"https:\/\/studaca.online\/api\/wp\/v2\/posts\/722\/revisions\/1085"}],"wp:attachment":[{"href":"https:\/\/studaca.online\/api\/wp\/v2\/media?parent=722"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/studaca.online\/api\/wp\/v2\/categories?post=722"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/studaca.online\/api\/wp\/v2\/tags?post=722"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}