Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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 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

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Beginning ASP.NET 2.0 And Databases

Authors: John Kauffman, Bradley Millington

1st Edition

0471781347, 978-0471781349

More Books

Students also viewed these Databases questions

Question

In an Excel Pivot Table, how is a Fact/Measure Column repeated?

Answered: 1 week ago