PageSourceSearch

https://pjlibrary.org/CMSPages/GetResource.ashx?scriptfile=/pjenro…/enrollment-form.js?v=2026.09.24.5.37

js pjlibrary.org collected 2026-09-24 09:37:46 UTC 5,352 bytes, 1 lines download raw bytes

1PJEnroll.module("EnrollmentForm",function(n){n.validate_ParentGuardian_Required=function(n,t){t.IsValid=$("[data-field='parent-or-guardian'] input:checked").val()=="rbParentGuardianNo"?t.Value!="":!0};n.validate_ParentGuardian_Email=function(n,t){if($("[data-field='parent-or-guardian'] input:checked").val()=="rbParentGuardianNo")t.IsValid=/\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*/.test(t.Value);else t.IsValid=!0};n.validate_ParentGuardian_Phone=function(n,t){if($("[data-field='parent-or-guardian'] input:checked").val()=="rbParentGuardianNo"){var i=new RegExp("^[0-9-]*$");t.IsValid=i.test(t.Value)}else t.IsValid=!0};n.validate_Language_Other=function(n,t){t.IsValid=$("[data-field='language-other'] input").is(":checked")?t.Value!="":!0};n.validate_Checkbox=function(n,t){var i=$(n).closest(".checkbox-group").find("input[type='checkbox']");t.IsValid=i.is(":checked")};n.validate_Language_checkboxes=function(n,t){var i=$(".langCheckBoxError").eq(0),r=$(n).closest(".checkbox-group").find("input[type='checkbox']");t.IsValid=$(".list-language :checked").length>0;t.IsValid?(i.text(""),i[0].style.visibility="hidden"):(i.text(i[0].getAttribute("data-error-text")),i[0].style.visibility="visible")};showHideParentGuardian=function(){var n=$("[data-field='parent-zipcode']"),t=$("[data-field='is-parent-military'] label");$("[data-field='parent-or-guardian'] input:checked").val()=="rbParentGuardianNo"?($("#pnlParentGuardian").show(),$("#phTextOptIn").hide(),$(".textoptin").children("input").first()[0].checked=!1,n.attr("placeholder","Parent/Guardian "+n.data("postal-label")+" Code*"),t.text("Parent or guardian is an active member of the U.S. military")):($("#pnlParentGuardian").hide(),$("#phTextOptIn").show(),n.attr("placeholder","Your "+n.data("postal-label")+" Code*"),t.text("I am an active member of the U.S. military"))};enableDisableParentGuardian=function(){var t=$("[data-field='check-terms-accept1'] input"),n=$("[data-field='check-jewish-confirm'] input"),i=typeof t!="undefined"&&t!=null&&t.length==1,r=typeof n!="undefined"&&n!=null&&n.length==1,u;i&&r&&!t.is(":checked")?n.attr("disabled",!0):n.attr("disabled",!1);u=(!i||t.is(":checked"))&&(!r||n.is(":checked"));(i||r)&&($("#parent-selector :input").attr("disabled",!u),$("input.btn[id*=btnStep1Next]").attr("disabled",!u))};showHideJoinMilitaryCommunity=function(){$("[data-field='is-parent-military'] input").is(":checked")?$("[data-field='join-military-community']").show():$("[data-field='join-military-community']").hide()};formatPostalCode_UK=function(n){var u="[abcdefghijklmnoprstuwyz]",o="[abcdefghklmnopqrstuvwxy]",f="[abdefghjlnpqrstuwxyz]",t=[],i,e,r;for(t.push(new RegExp("^(bf1)(\\s*)([0-6]{1}[abdefghjlnpqrst]{1}[abdefghjlnpqrstuwzyz]{1})$","i")),t.push(new RegExp("^("+u+"{1}"+o+"?[0-9]{1,2})(\\s*)([0-9]{1}"+f+"{2})$","i")),t.push(new RegExp("^("+u+"{1}[0-9]{1}[abcdefghjkpmnrstuvwxy]{1})(\\s*)([0-9]{1}"+f+"{2})$","i")),t.push(new RegExp("^("+u+"{1}"+o+"{1}?[0-9]{1}[abehmnprvwxy]{1})(\\s*)([0-9]{1}"+f+"{2})$","i")),t.push(/^(GIR)(\s*)(0AA)$/i),t.push(/^(bfpo)(\s*)([0-9]{1,4})$/i),t.push(/^(bfpo)(\s*)(c\/o\s*[0-9]{1,3})$/i),t.push(/^([A-Z]{4})(\s*)(1ZZ)$/i),t.push(/^(ai-2640)$/i),i=n,e=!1,r=0;r<t.length;r++)if(t[r].test(i)){t[r].exec(i);i=RegExp.$1.toUpperCase()+" "+RegExp.$3.toUpperCase();i=i.replace(/C\/O\s*/,"c/o ");n.toUpperCase()=="AI-2640"&&(i="AI-2640");e=!0;break}return e?i:!1};formatPostalCode_USCanada=function(n){var t=n,i;return t!=undefined&&t!=""&&(t=t.trim(),i=t.length,i==6?t=(t.substring(0,3)+" "+t.substring(3,6)).toUpperCase():(i==9||i==10)&&(t=t.substring(0,5))),t};n.init=function(){$("[data-field='parent-or-guardian'] input").click(function(){showHideParentGuardian()});showHideParentGuardian();$("[data-field='check-terms-accept1'] input").click(function(){enableDisableParentGuardian()});$("[data-field='check-jewish-confirm'] input").click(function(){enableDisableParentGuardian()});enableDisableParentGuardian();$("[data-field='is-parent-military'] input").click(function(){showHideJoinMilitaryCommunity()});showHideJoinMilitaryCommunity();$("[data-field='is-parent-military'] input, [data-field='join-military-community-btn'] input").click(function(){$("[data-func='find-community']").trigger("click")});$("[data-restriction='no-spaces']").keydown(function(n){if(n.keyCode===32)return n.preventDefault(),!1}).blur(function(){for(var n=$(this).val();n.indexOf(" ")!==-1;)n=n.replace(" ","");$(this).val(n)});$("[data-restriction='trim']").blur(function(){var n=$(this).val();$(this).val(n.trim())});$("a.disabled").removeAttr("href");var n=function(n,t){return n.val()!=""?n.val()!=n.data("last-async-value")?($("#txtCommunityId").val(""),$("[data-func='find-community']").trigger("click"),t&&t.preventDefault(),n.data("last-async-value",n.val()),!0):!1:!0},t=function(n){var i=n.data("format"),t;i=="UK"?(t=formatPostalCode_UK(n.val()),t&&n.val(t)):i=="USCanada"&&(t=formatPostalCode_USCanada(n.val()),t&&n.val(t))};$("[data-field='parent-zipcode']").blur(function(){t($(this));n($(this),null)});$("[data-field='parent-zipcode']").keypress(function(i){if(i.keyCode==13)return t($(this)),n($(this),i)||$("input.btn[id*=btnStep1Next]").click(),!1});
1$(".showHideJewishConfirm").change(function(){$(".showHideJewishConfirm").first().is(":checked")?$("#step1FormDisplay").show():$("#step1FormDisplay").hide()})};n.init()})

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.