HTTP/1.1 200 OK set-cookie: PHPSESSID=218fida8iokh1pt48tk9dri9g4; path=/ expires: Thu, 19 Nov 1981 08:52:00 GMT cache-control: no-store, no-cache, must-revalidate pragma: no-cache content-type: text/html; charset=UTF-8 x-content-type-options: nosniff set-cookie: pll_language=vi; expires=Wed, 30 Sep 2026 23:09:09 GMT; Max-Age=31536000; path=/; secure; SameSite=Lax link: ; rel="https://api.w.org/" link: ; rel="alternate"; title="JSON"; type="application/json" link: ; rel=shortlink transfer-encoding: chunked date: Tue, 30 Sep 2025 23:09:10 GMT server: LiteSpeed alt-svc: h3=":443"; ma=2592000, h3-29=":443"; ma=2592000, h3-Q050=":443"; ma=2592000, h3-Q046=":443"; ma=2592000, h3-Q043=":443"; ma=2592000, quic=":443"; ma=2592000; v="43,46" connection: Keep-Alive Tra cứu văn bằng - Cao Đẳng Viễn Đông

Bạn đang tìm kiếm gì?

icon-vn
Đăng ký
zalo other

'); $(document).on('click', "#form-diploma button[type='submit']", function (event) { event.preventDefault(); var number = 'diploma_number'; var inputDiplomaValue = $('div[data-name="diploma_number"]').find('input').val(); if (inputDiplomaValue) { var formatValue = inputDiplomaValue.trim().replace(/ /g, '_'); const form = $(this).closest('.af-form'); acf.lockForm(form); // Hiển thị loading khi submit form $('#loading-spinner').show(); $('#diploma-table').hide(); $('#empty-result').hide(); $('.table-mobile').hide(); const data = acf.serialize(form); data.action = 'af_submission'; $.ajax({ url: '/wp-admin/admin-ajax.php', data: acf.prepareForAjax(data), type: 'post', dataType: 'json', error(jqXHR, textStatus, errorThrown) { const data = jqXHR.responseJSON; alert(`OH NO! ${acf.maybe_get(data, 'message')}`); acf.unlockForm(form); // Reset the ACF form back to normal. $('#loading-spinner').hide(); }, success(data, textStatus, jqXHR) { if (data.success === true) { form[0].reset(); getDiploma(formatValue); } else { // Errors should be caught before this point, but you never know alert(`OH NO! ${acf.maybe_get(data, 'message')}`); }; }, complete(jqXHR, textStatus) { acf.unlockForm(form); } }); } }); function getDiploma(number) { var urlWithParams = apiUrl + `?number=${number}`; $.ajax({ url: urlWithParams, type: "GET", contentType: "application/json", success: function (response) { console.log("success: ", response); $('#loading-spinner').hide(); if (response?.status && response?.payload) { if(window.innerWidth ${response?.payload?.number} ${response?.payload?.name} ${response?.payload?.dateOfBirth} ${response?.payload?.gradutateDate} ${response?.payload?.subject} ${response?.payload?.numberInBook} `; $('#diploma-table tbody').html(tableRows); // Cập nhật nội dung bảng } } else { // Nếu không có dữ liệu $('#diploma-table').hide(); // Ẩn bảng nếu không có dữ liệu $('.table-mobile').hide(); $('#empty-result').show(); } }, error: function (jqXHR, textStatus, errorThrown) { console.error("Error:", textStatus, errorThrown); $('#loading-spinner').hide(); } }); } });