Question
I want the website to be able to send the form data to a CSV file or Word Macros. Currently, it sends the form data
I want the website to be able to send the form data to a CSV file or Word Macros. Currently, it sends the form data to a .txt file only for personal information. I would also like to send all the form data including personal info, education and work experience to a .txt file. But ideally I would like it to be sent to a CSV file. I am not 100% sure if this could be done without any backend langauge but I appreciate any help. It would be nice if you can modify the code so it will send form data to excel file creating a sort of database. I am attaching the required code.
Build.html:
WEBSITE
- Build a Resume
- Create Account
- Sign in
- Resources
- Talk to us
Build your resume here!
YOUR PERSONAL INFO
YOUR EDUCATIONAL BACKGROUND
YOUR WORK EXPERIENCE
Main.js:
function saveFormAsTextFile() { var textToSave = ' '+ 'First Name: ' + document.getElementById('first_name').value + ' ' + 'Last Name: ' + document.getElementById('last_name').value + ' ' + 'Email: ' + document.getElementById('user_email').value + ' ' + 'Phone Number: ' + document.getElementById('phone_number').value + ' ' + 'Location: ' + document.getElementById('location').value + ' ' + 'LinkedIn: ' + document.getElementById('linkedin').value + ' ' ;
var textToSaveAsBlob = new Blob([textToSave], {type:"text/plain"}); var textToSaveAsURL = window.URL.createObjectURL(textToSaveAsBlob); var fileNameToSaveAs = document.getElementById("filename").value;
var downloadLink = document.createElement("a"); downloadLink.download = fileNameToSaveAs; downloadLink.innerHTML = "Download File"; downloadLink.href = textToSaveAsURL; downloadLink.onclick = destroyClickedElement; downloadLink.style.display = "none"; document.body.appendChild(downloadLink);
downloadLink.click(); }
function destroyClickedElement(event) { document.body.removeChild(event.target); }
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started