Add A Subject And Body Text To A HTML Mailto Command

Written by Allen White on. Posted in Web, Web Browsers

This is not really my sort of thing but I noticed that when companies  have enquiry email addresses they sometimes automatically fill the subject field in the email and sometimes even fill part of the email body out. I was wondering how they did this so had a dig into it.

So normally you use the command below to email making sure you open and close the command with < and >.

<a href=""></a>

As you will see if you click on the email address above it will open up your mail client and populate the email field. To add a subject use the command below.

<a href=" your subject here"></a>

Now you will see that if you click on you will see that the subject field is populated.

Finally, if you would like to add content to the body of the email use the command below.

<a href=" your subject here&body=whatever txt you want in the body"></a>

So now when you click on you will see the body and field is pre populated in the email

Allen White
Allen is a Consultant for ITPS in the North East of England and holds the following accreditations. MCSA, MCSE, MCTS, MCITP, CCA, CCSP, VCP 4,5 and HP ASE, AIS - Network Infrastructure.

ITPS provides strategic IT consultancy, implementation, data centre provision and unified communications, as well as support services and workspace and disaster recovery. If you require a consultation then please contact me via the contacts section or direct on 07931222991, add me on linkedin.


Leave a comment


(c) Please be aware, all information is provided freely, any information used is done so at your risk and Techieshelp will not be held responsible for any issue that may occur.
!-- BuySellAds On-Site Shopping Cart -->