{"id":1159,"date":"2012-11-29T00:47:01","date_gmt":"2012-11-29T00:47:01","guid":{"rendered":"http:\/\/www.phpmind.com\/blog\/?p=1159"},"modified":"2012-11-29T00:47:01","modified_gmt":"2012-11-29T00:47:01","slug":"javascript-terms-condition-checkbox-validation","status":"publish","type":"post","link":"https:\/\/www.phpmind.com\/blog\/2012\/11\/javascript-terms-condition-checkbox-validation\/","title":{"rendered":"Javascript terms &#038; condition checkbox validation"},"content":{"rendered":"<p>Most of the form have terms &#038; condition and they required user to select checkbox if checkbox is not selected foem will not post. <\/p>\n<p>This is very simple example. <\/p>\n<pre lang=\"html\">\r\n<form method=\"POST\" action=\"http:\/\/www.phpmind.com\">\r\n <input type=\"checkbox\" name=\"checkbox\" value=\"check\"  \/>\r\n <input type=\"submit\" name=\"submit\" value=\"submit\" onclick=\"if(!this.form.checkbox.checked){alert('You must agree to the terms first.');return false}\"  \/>\r\n<\/form>\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Most of the form have terms &#038; condition and they required user to select checkbox if checkbox is not selected foem will not post. This is very simple example.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_exactmetrics_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0,"footnotes":""},"categories":[27],"tags":[],"class_list":["post-1159","post","type-post","status-publish","format-standard","hentry","category-javascript"],"_links":{"self":[{"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/posts\/1159","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/comments?post=1159"}],"version-history":[{"count":1,"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/posts\/1159\/revisions"}],"predecessor-version":[{"id":1160,"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/posts\/1159\/revisions\/1160"}],"wp:attachment":[{"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/media?parent=1159"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/categories?post=1159"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.phpmind.com\/blog\/wp-json\/wp\/v2\/tags?post=1159"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}