{"id":3730,"date":"2025-01-15T08:39:41","date_gmt":"2025-01-15T08:39:41","guid":{"rendered":"https:\/\/mpqua.upsi.edu.my\/?page_id=3730"},"modified":"2025-01-16T07:38:10","modified_gmt":"2025-01-16T07:38:10","slug":"mpqua-members-sign-in","status":"publish","type":"page","link":"https:\/\/mpqua.upsi.edu.my\/index.php\/mpqua-members-sign-in\/","title":{"rendered":"MPQUA MEMBERS SIGN IN"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-page\" data-elementor-id=\"3730\" class=\"elementor elementor-3730\" data-elementor-post-type=\"page\">\n\t\t\t\t<div class=\"elementor-element elementor-element-748f15f e-grid e-con-boxed e-con e-parent\" data-id=\"748f15f\" data-element_type=\"container\" data-settings=\"{&quot;background_background&quot;:&quot;classic&quot;}\">\n\t\t\t\t\t<div class=\"e-con-inner\">\n\t\t\t\t<div class=\"elementor-element elementor-element-cbfe9f0 elementor-widget elementor-widget-html\" data-id=\"cbfe9f0\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<div class=\"swiper-slide\" data-content=\"content-1\" style=\"\">\n  <!-- Tab 1 Slide -->\n    <h3 id=\"month-name\" >SIGN IN<\/h3>\n    <h5 id=\"month-desc\"><\/h5>\n<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t<div class=\"elementor-element elementor-element-2b5bbfd e-flex e-con-boxed e-con e-parent\" data-id=\"2b5bbfd\" data-element_type=\"container\">\n\t\t\t\t\t<div class=\"e-con-inner\">\n\t\t\t\t<div class=\"elementor-element elementor-element-bf713fc elementor-widget elementor-widget-html\" data-id=\"bf713fc\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<html>\r\n<head>\r\n  <meta charset=\"utf-8\">\r\n  <script src=\"https:\/\/cdn.jsdelivr.net\/npm\/sweetalert2@11\"><\/script>\r\n  <script src=\"https:\/\/code.jquery.com\/jquery-3.6.0.min.js\"><\/script>\r\n\r\n    <script>\r\n    \/\/ Clear session data on page load (logout state)\r\n    window.onload = function() {\r\n        sessionStorage.removeItem('loggedIn');\r\n    };\r\n         const SHEET_URL = \"https:\/\/script.google.com\/macros\/s\/AKfycby6ghvzt7ll-GVNxVeOYSycPNmn4GkVzTKHrfwueM0y9QoRu-bcn_UsAuN0H4F3zTpt\/exec\"; \/\/ Replace with your Apps Script URL\r\n\r\n    let credentials = [];\r\n\r\n    \/\/ Fetch credentials from the Google Sheet\r\n    $.getJSON(SHEET_URL, function(data) {\r\n        credentials = data; \/\/ Store fetched data\r\n    });\r\n\r\n    function login() {\r\n        const username = document.getElementById('username').value;\r\n        const password = document.getElementById('password').value;\r\n\r\n        \/\/ Check if username and password match any entry\r\n        const user = credentials.find(cred => cred.Username === username && cred.Password === password);\r\n\r\n        if (user) {\r\n            sessionStorage.setItem('loggedIn', true);\r\n            Swal.fire({\r\n                icon: 'success',\r\n                title: 'Login Successful!',\r\n                text: `Welcome, ${user.Name}! Redirecting to the protected page...`,\r\n                timer: 2000,\r\n                showConfirmButton: false\r\n            }).then(() => {\r\n                window.location.href = \"https:\/\/mpqua.upsi.edu.my\/index.php\/assessors-list\/\"; \/\/ Redirect\r\n            });\r\n        } else {\r\n            Swal.fire({\r\n                icon: 'error',\r\n                title: 'Login Failed!',\r\n                text: 'Invalid username or password.',\r\n                confirmButtonText: 'Try Again'\r\n            });\r\n        }\r\n    }\r\n    <\/script>\r\n<\/head>\r\n\r\n<body>\r\n  <div class=\"login-root\">\r\n    <div class=\"box-root flex-flex flex-direction--column\" style=\"min-height: 100vh;flex-grow: 1;\">\r\n      <div class=\"loginbackground box-background--white padding-top--64\">\r\n        <div class=\"loginbackground-gridContainer\">\r\n          <div class=\"box-root flex-flex\" style=\"grid-area: top \/ start \/ 8 \/ end;\">\r\n            <div class=\"box-root\" style=\"background-image: linear-gradient(white 0%, rgb(247, 250, 252) 33%); flex-grow: 1;\">\r\n            <\/div>\r\n          <\/div>\r\n          <div class=\"box-root flex-flex\" style=\"grid-area: 4 \/ 2 \/ auto \/ 5;\">\r\n            <div class=\"box-root box-divider--light-all-2 animationLeftRight tans3s\" style=\"flex-grow: 1;\"><\/div>\r\n          <\/div>\r\n          <div class=\"box-root flex-flex\" style=\"grid-area: 6 \/ start \/ auto \/ 2;\">\r\n            <div class=\"box-root box-background--blue800\" style=\"flex-grow: 1;\"><\/div>\r\n          <\/div>\r\n          <div class=\"box-root flex-flex\" style=\"grid-area: 7 \/ start \/ auto \/ 4;\">\r\n            <div class=\"box-root box-background--blue animationLeftRight\" style=\"flex-grow: 1;\"><\/div>\r\n          <\/div>\r\n          <div class=\"box-root flex-flex\" style=\"grid-area: 8 \/ 4 \/ auto \/ 6;\">\r\n            <div class=\"box-root box-background--gray100 animationLeftRight tans3s\" style=\"flex-grow: 1;\"><\/div>\r\n          <\/div>\r\n          <div class=\"box-root flex-flex\" style=\"grid-area: 2 \/ 15 \/ auto \/ end;\">\r\n            <div class=\"box-root box-background--cyan200 animationRightLeft tans4s\" style=\"flex-grow: 1;\"><\/div>\r\n          <\/div>\r\n          <div class=\"box-root flex-flex\" style=\"grid-area: 3 \/ 14 \/ auto \/ end;\">\r\n            <div class=\"box-root box-background--blue animationRightLeft\" style=\"flex-grow: 1;\"><\/div>\r\n          <\/div>\r\n          <div class=\"box-root flex-flex\" style=\"grid-area: 4 \/ 17 \/ auto \/ 20;\">\r\n            <div class=\"box-root box-background--gray100 animationRightLeft tans4s\" style=\"flex-grow: 1;\"><\/div>\r\n          <\/div>\r\n          <div class=\"box-root flex-flex\" style=\"grid-area: 5 \/ 14 \/ auto \/ 17;\">\r\n            <div class=\"box-root box-divider--light-all-2 animationRightLeft tans3s\" style=\"flex-grow: 1;\"><\/div>\r\n          <\/div>\r\n        <\/div>\r\n      <\/div>\r\n      <div class=\"box-root padding-top--24 flex-flex flex-direction--column\" style=\"flex-grow: 1; z-index: 9;\">\r\n        <div class=\"box-root padding-top--48 padding-bottom--24 flex-flex flex-justifyContent--center\">\r\n            <div class=\"footer-link note\">\r\n            <span>This content is restricted to MPQUA members only. Please enter your password below to access it.<\/span>\r\n          <\/div>\r\n         \r\n        <\/div>\r\n        <div class=\"formbg-outer\">\r\n          <div class=\"formbg\">\r\n            <div class=\"formbg-inner padding-horizontal--48\">\r\n                <img fetchpriority=\"high\" fetchpriority=\"high\" decoding=\"async\" width=\"941\" height=\"387\" src=\"https:\/\/mpqua.upsi.edu.my\/wp-content\/uploads\/2024\/07\/MPQUA-LOGO.png\" alt=\"\" class=\"wp-image-923\" srcset=\"https:\/\/mpqua.upsi.edu.my\/wp-content\/uploads\/2024\/07\/MPQUA-LOGO.png 941w, https:\/\/mpqua.upsi.edu.my\/wp-content\/uploads\/2024\/07\/MPQUA-LOGO-300x123.png 300w, https:\/\/mpqua.upsi.edu.my\/wp-content\/uploads\/2024\/07\/MPQUA-LOGO-768x316.png 768w\" sizes=\"(max-width: 941px) 100vw, 941px\">\r\n                  <h1>SIGN IN<\/h1>\r\n              <span class=\"padding-bottom--15\"><\/span>\r\n              <form id=\"stripe-login\" onsubmit=\"login(); return false;\">\r\n                <div class=\"field padding-bottom--24\">\r\n                  <label for=\"email\">Username<\/label>\r\n                  <input type=\"text\" id=\"username\" required placeholder=\"Username\">\r\n                <\/div>\r\n                <div class=\"field padding-bottom--24\">\r\n                  <div class=\"grid--50-50\">\r\n                    <label for=\"password\">Password<\/label>\r\n                  <\/div>\r\n                  <input type=\"password\" placeholder=\"Password\" id=\"password\" required>\r\n                <\/div>\r\n                <div class=\"field padding-bottom--24\">\r\n                  <input type=\"submit\" name=\"submit\" value=\"Continue\">\r\n                <\/div>\r\n              <\/form>\r\n            <\/div>\r\n          <\/div>\r\n        <\/div>\r\n      <\/div>\r\n    <\/div>\r\n  <\/div>\r\n<\/body>\r\n\r\n<\/html>\r\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>SIGN IN This content is restricted to MPQUA members only. Please enter your password below to access it. SIGN IN Username Password<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"elementor_header_footer","meta":{"footnotes":""},"class_list":["post-3730","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/mpqua.upsi.edu.my\/index.php\/wp-json\/wp\/v2\/pages\/3730","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mpqua.upsi.edu.my\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/mpqua.upsi.edu.my\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/mpqua.upsi.edu.my\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mpqua.upsi.edu.my\/index.php\/wp-json\/wp\/v2\/comments?post=3730"}],"version-history":[{"count":64,"href":"https:\/\/mpqua.upsi.edu.my\/index.php\/wp-json\/wp\/v2\/pages\/3730\/revisions"}],"predecessor-version":[{"id":3831,"href":"https:\/\/mpqua.upsi.edu.my\/index.php\/wp-json\/wp\/v2\/pages\/3730\/revisions\/3831"}],"wp:attachment":[{"href":"https:\/\/mpqua.upsi.edu.my\/index.php\/wp-json\/wp\/v2\/media?parent=3730"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}