Saket Jajodia

Tecko Blog..!!

Follow me on Twitter @

How To Make Use Of Mailto Link Syntax

When we mention our email address on our website we simply add a mailto hyper link with it which converts that text email address into a clickable link and when people click on it, it will open email composer of your default email manager and your email address will be pre-mentioned at sender place (if you use Firefox then you can set your favorite email service provider or email manager).

But do you know apart from pre-mentioning email address at sender place you can also pre-mention other parts of email composer fields like, To, Cc, Bcc, Subject and Body.

Add Multiple Email Addresses

mailto:Jajodia.Saket@gmail.com,Saket@d2d.co,admin@SJbn.Co

Mention CC

cc=Jajodia.Saket@gmail.com

Mention BCC

bcc=admin@SJbn.Co

Add subject line

subject=Subject%20text%20goes%20here

Add text in body

body=Your%20body%20text%20will%20go%20here

You can use all or some of these mentioned above attributes to create a mailto link. To combine them you need to use ampersand (&) and question mark (?). Make sure question mark can only be used once in the link, see the below example.

mailto:Saket@d2d.co?cc=Jajodia.Saket@gmail.com&bcc=admin@SJbn.Co&subject=Subject%20text%20goes%20here&body=Your%20body%20text%20will%20go%20here

This is how it will appear after clicking on type of mailto link mention above

And to use it in your blog or website, add it in anchor text hyperlink (as shown below).

<a href="mailto:Saket@d2d.co?cc=Jajodia.Saket@gmail.com&bcc=admin@SJbn.Co&subject=Subject%20text%20goes%20here&body=Your%20body%20text%20will%20go%20here">your clickable text goes here</a>

Tip: – To give blank space in between text use %20 and to break and start from new line use %0a or %0A.

Note: – Within mailto URLs, the characters ?, = and & are reserved. It means you can’t use these in your message body or subject line, in case if you need to use them then use these characters, for Question Mark (?) use &#63;, for Equal Sign (=) use &#61; and for Ampersand or And Sign (&) you can use &amp; or &#38;.

Reply

Please use your original name while commenting, Thank you..!!








Designed by Blogger Templates and Blog and Web