3

We need to attached multiple document in mail to in by using JavaScript or j query.

We need to attached my document path must be live URI Like: http://www.axmag.com/download/pdfurl-guide.pdf

My Code is Like: HTML:

<a onclick="sendmaildocument();">Mail</a>

JavaScript:

function sendmaildocument()
{   
   document.location = "mailto:user@example.com?attach="+"http://www.axmag.com/download/pdfurl-guide.pdf";
} 

Please help me..!

piyush
  • 554
  • 5
  • 14

1 Answers1

3

No, you can not add an attachment to a message with the mailto: URL scheme. mailto: only supports header values or text/plain content. See RFC 2368 for details.

fabpolli
  • 56
  • 5
  • Right, So i there any other option to attached document in mail by using JavaScript, j query or Ajax? – piyush Jul 14 '15 at 09:03
  • javascript and jquery can't send mail with attachment. With Ajax you can call a PHP page, take a look to this answer [link](http://stackoverflow.com/a/12302354/2298792) – fabpolli Jul 14 '15 at 09:11