(DISCLAIMER: I am very new to HTML/CSS/JavaScript, so apologies if my code is whacky)
I am looking for a way to generate an email with an email attachment. Here is my code:
<body>
<form action="mailto:example3@example.com" method="GET">
<label for="cc">Cc Line Addresses:</label>
<br>
<input id="cc" name="cc" type="email multiple" value="example1@example.com;example2@example.com"/>
<br>
<br>
<label for="subject" >Enter your subject below:</label>
<br>
<input type="text" name="subject" id="subject">
<br>
<br>
<label for="body" >Enter the Email Body below:</label>
<br><textarea id="body" name="body" rows="5" cols="50">Example body</textarea>
<br>
<br>
<label for= "myFile">Click below to upload your attachment file</label>
<!-- This is where I want the attachment to flow to the email-->
<br>
<br>
<input type="file" id="myFile" name="attachment" class="fileUpload">
<br>
<br>
<strong><label for="submit">Click Below to Generate New Email</label></strong>
<br>
<input type="submit" id="submit" value="Generate">
</form>
</body>
I would like to use Javascript to have the uploaded file from the HTML form attach to the email generated by the submit button (opened with the default email client).
Thanks!