From 9f17130a8e4ee714d881b2e9ade554e288668b0f Mon Sep 17 00:00:00 2001 From: Apo-orva17 Date: Sat, 13 Sep 2025 22:21:30 +0530 Subject: [PATCH] Solved issue #112:autodownload off for when the input is entered in incorrect format --- script.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/script.js b/script.js index e560e4a..5c5b099 100644 --- a/script.js +++ b/script.js @@ -236,7 +236,8 @@ function validateForm() { if (isValid) return true; // Else ask user if they want to proceed anyway - return confirm("Please correct the highlighted errors in the form before downloading your resume."); + else alert("Please correct the highlighted errors in the form before downloading your resume."); + return false; } @@ -245,8 +246,7 @@ document.getElementById("downloadBtn").addEventListener("click", () => { if (!validateForm()) return; // --- PDF Download Button --- - - const content = document.querySelector('#resume-sections'); +const content = document.querySelector('#resume-sections'); const options = { margin: 0.5, filename: 'resume.pdf',