/form2mailto

API-free, Bot-Spam filter, JavaScript for email form submission sending

Primary LanguageJavaScriptThe UnlicenseUnlicense

( this repository now lives at https://gitlab.com/alexandre1985/form2mailto/ )

Form2Mailto

API-free, Bot-Spam filter, JavaScript for email form submission sending.
Written in Plain JavaScript (no frameworks) 🌍 🐦

Install

Just add this JavaScript to your HTML page that has a form, and, also, add the HTML attribute data-email="youremail@address.com" to the form.

After install

You may want/need to edit the code of the email, subject, name, text variables. To correspond to your form's fields. Or just change your form's HTML.

It is a JavaScript very small and easy to read.

About

What does it do?

It converts the input of the HTML form into a email ready to be sent; using the mailto: URI.

Advantages

  • No need for Back-End language
  • No need to subscribe to any email third-party service
  • It may be a good security measure to filter out your form's spam

Disavantages

  • You may need to educate your website visitor how to disable browser's mailto link "security" block
  • You may need to tell an uneducated visitor that it need to click on "Send" in his email web/desktop client

LICENSE

UNLICENSE (Public Domain)